Currently the @AnnotateWith annotation modification on the original method is automatically passed to its forgeMethod method, should we change it to an optional one, regarding whether it is automatically passed to its derived method
e.g. currently for
@Mapper
public interface AnnotationForgeMapper {
@AnnotateWith( CustomMethodOnlyAnnotation.class )
List<Target> map(List<Source> sources);
}
will generate
public class AnnotationForgeMapperImpl implements AnnotationForgeMapper {
@CustomMethodOnlyAnnotation
@Override
public List<Target> map(List<Source> sources) {
if ( sources == null ) {
return null;
}
List<Target> list = new ArrayList<Target>( sources.size() );
for ( Source source : sources ) {
list.add( sourceToTarget( source ) );
}
return list;
}
@CustomMethodOnlyAnnotation
protected Target sourceToTarget(Source source) {
if ( source == null ) {
return null;
}
Target target = new Target();
target.setValue( source.getValue() );
return target;
}
}
We can see that the sourceToTarget method also carries the CustomMethodOnlyAnnotation annotation
Currently the
@AnnotateWithannotation modification on the original method is automatically passed to itsforgeMethodmethod, should we change it to an optional one, regarding whether it is automatically passed to its derived methode.g. currently for
will generate
We can see that the
sourceToTargetmethod also carries theCustomMethodOnlyAnnotationannotation