public void addAll(Annotations toAdd) {
    throwIfImmutable();

    if (toAdd == null) {
      throw new NullPointerException("toAdd == null");
    }

    for (Annotation a : toAdd.annotations.values()) {
      add(a);
    }
  }
Adds all of the elements of the given instance to this one. The instances must not have any
duplicate types.

@param toAdd {@code non-null;} the annotations to add
@throws IllegalArgumentException thrown if there is a duplicate type
android/android_framework/dex-maker/src/main/java/com/android/dx/rop/annotation/Annotations.java