static Rel findRel ( Method method ) { Rel rootRel = method . getDeclaringClass ( ) . getAnnotation ( Rel . class ) ; Rel rel = method . getAnnotation ( Rel . class ) ; if ( rel != null ) { return rel ; } else if ( rootRel != null ) { return rootRel ; } return null ; }
Finds a the rel of a method . The rel can be found on the declaring class but the rel on the method will have the precedence .