in commons-digester3-core/src/main/java/org/apache/commons/digester3/annotations/handlers/AbstractMethodHandler.java [56:93]
protected abstract void doBind( String pattern, String namespaceURI, Method method, Class<?> type,
boolean fireOnBegin, RulesBinder rulesBinder );
private void doHandle( final A methodAnnotation, final Annotation annotation, final Method method, final Class<?> type,
final boolean fireOnBegin, final RulesBinder rulesBinder )
{
if ( annotation.annotationType().isAnnotationPresent( DigesterRule.class )
&& annotation.annotationType().isAnnotationPresent( CreationRule.class ) )
{
rulesBinder.install( new FromAnnotationsRuleModule()
{
@Override
protected void configureRules()
{
bindRulesFrom( type );
}
} );
final String pattern = getAnnotationPattern( annotation );
final String namespaceURI = getAnnotationNamespaceURI( annotation );
doBind( pattern, namespaceURI, method, type, fireOnBegin, rulesBinder );
}
else if ( annotation.annotationType().isAnnotationPresent( DigesterRuleList.class ) )
{
// check if it is one of the *.List annotation
final Annotation[] annotations = getAnnotationsArrayValue( annotation );
if ( annotations != null )
{
// if it is an annotations array, process them
for ( final Annotation ptr : annotations )
{
doHandle( methodAnnotation, ptr, method, type, fireOnBegin, rulesBinder );
}
}
}
}