private void checkMethodAnnotations(Method method, JavaInterface javaInterface) throws InvalidAnnotationException {
for ( Annotation a : method.getAnnotations() ) {
if( a instanceof Remotable ) {
// [JCA90053] @Remotable annotation cannot be on a method that is not a setter method
if( !JavaIntrospectionHelper.isSetter(method) ) {
throw new InvalidAnnotationException("[JCA90053] @Remotable annotation present on an interface method" +
" which is not a Setter method: " + javaInterface.getName() + "/" + method.getName(), Remotable.class);
} // end if
} // end if
} // end for
// Parameter annotations
for (Annotation[] parmAnnotations : method.getParameterAnnotations()) {
for (Annotation annotation : parmAnnotations) {
if (annotation instanceof Remotable ) {
throw new InvalidAnnotationException("[JCA90053] @Remotable annotation present on an interface method" +
" parameter: " + javaInterface.getName() + "/" + method.getName(), Remotable.class);
} // end if
} // end for
} // end for
method.getParameterAnnotations();