/** * Copy constructor. * * @param prototype the prototype */ protected AnnotationImpl(Annotation prototype) { requireNonNull(prototype); name = prototype.getName(); javadoc = prototype.getJavadoc().map(Copier::copy).orElse(null); annotations = Copier.copy(prototype.getAnnotations()); fields = Copier.copy(prototype.getFields()); imports = Copier.copy(prototype.getImports()); modifiers = Copier.copy(prototype.getModifiers(), c -> c.copy(), EnumSet.noneOf(Modifier.class)); }
/** * Copy constructor. * * @param prototype the prototype */ protected AnnotationImpl(Annotation prototype) { requireNonNull(prototype); name = prototype.getName(); javadoc = prototype.getJavadoc().map(Copier::copy).orElse(null); annotations = Copier.copy(prototype.getAnnotations()); fields = Copier.copy(prototype.getFields()); imports = Copier.copy(prototype.getImports()); modifiers = Copier.copy(prototype.getModifiers(), c -> c.copy(), EnumSet.noneOf(Modifier.class)); }
/** * Copy constructor. * * @param prototype the prototype */ protected AnnotationImpl(Annotation prototype) { requireNonNull(prototype); name = prototype.getName(); javadoc = prototype.getJavadoc().map(Copier::copy).orElse(null); annotations = Copier.copy(prototype.getAnnotations()); fields = Copier.copy(prototype.getFields()); imports = Copier.copy(prototype.getImports()); modifiers = Copier.copy(prototype.getModifiers(), c -> c.copy(), EnumSet.noneOf(Modifier.class)); }