public Set<MethodSignature> getLocalBusinessMethodSignatures() { Set<MethodSignature> businessMethodSignatures = new HashSet<MethodSignature>(); for (BusinessInterfaceDescriptor<?> businessInterfaceDescriptor : ejbDescriptor.getLocalBusinessInterfaces()) { for (Method m : businessInterfaceDescriptor.getInterface().getMethods()) { businessMethodSignatures.add(new MethodSignatureImpl(m)); } } return Collections.unmodifiableSet(businessMethodSignatures); }
public Set<MethodSignature> getRemoteBusinessMethodSignatures() { Set<MethodSignature> businessMethodSignatures = new HashSet<MethodSignature>(); for (BusinessInterfaceDescriptor<?> businessInterfaceDescriptor : ejbDescriptor.getRemoteBusinessInterfaces()) { for (Method m : businessInterfaceDescriptor.getInterface().getMethods()) { businessMethodSignatures.add(new MethodSignatureImpl(m)); } } return Collections.unmodifiableSet(businessMethodSignatures); }
protected Set<MethodSignature> getBusinessMethodSignatures() { Set<MethodSignature> businessMethodSignatures = new HashSet<MethodSignature>(); for (BusinessInterfaceDescriptor<?> businessInterfaceDescriptor : ejbDescriptor.getLocalBusinessInterfaces()) { for (Method m : businessInterfaceDescriptor.getInterface().getMethods()) { businessMethodSignatures.add(new MethodSignatureImpl(m)); } } for (BusinessInterfaceDescriptor<?> businessInterfaceDescriptor : ejbDescriptor.getRemoteBusinessInterfaces()) { for (Method m : businessInterfaceDescriptor.getInterface().getMethods()) { businessMethodSignatures.add(new MethodSignatureImpl(m)); } } return Collections.unmodifiableSet(businessMethodSignatures); }
private boolean isRemoveMethod(Method method) { MethodSignature methodSignature = new MethodSignatureImpl(method); return bean.getEjbDescriptor().getRemoveMethodSignatures().contains(methodSignature); }
private boolean isRemoveMethod(Method method) { // TODO we can certainly optimize this search algorithm! MethodSignature methodSignature = new MethodSignatureImpl(method); return bean.getEjbDescriptor().getRemoveMethodSignatures().contains(methodSignature); }
public static MethodSignature of(AnnotatedMethod<?> method) { if (method instanceof EnhancedAnnotatedMethod<?, ?>) { return Reflections.<EnhancedAnnotatedMethod<?, ?>>cast(method).getSignature(); } return new MethodSignatureImpl(method); }
public static MethodSignature of(AnnotatedMethod<?> method) { if (method instanceof EnhancedAnnotatedMethod<?, ?>) { return Reflections.<EnhancedAnnotatedMethod<?, ?>>cast(method).getSignature(); } return new MethodSignatureImpl(method); }
public static MethodSignature of(AnnotatedMethod<?> method) { if (method instanceof EnhancedAnnotatedMethod<?, ?>) { return Reflections.<EnhancedAnnotatedMethod<?, ?>>cast(method).getSignature(); } return new MethodSignatureImpl(method); }
public static MethodSignature of(AnnotatedMethod<?> method) { if (method instanceof EnhancedAnnotatedMethod<?, ?>) { return Reflections.<EnhancedAnnotatedMethod<?, ?>>cast(method).getSignature(); } return new MethodSignatureImpl(method); }
public static MethodSignature of(AnnotatedMethod<?> method) { if (method instanceof EnhancedAnnotatedMethod<?, ?>) { return Reflections.<EnhancedAnnotatedMethod<?, ?>>cast(method).getSignature(); } return new MethodSignatureImpl(method); }
public static MethodSignature of(AnnotatedMethod<?> method) { if (method instanceof EnhancedAnnotatedMethod<?, ?>) { return Reflections.<EnhancedAnnotatedMethod<?, ?>>cast(method).getSignature(); } return new MethodSignatureImpl(method); }
private InternalEjbDescriptor(EjbDescriptor<T> ejbDescriptor) { this.delegate = ejbDescriptor; this.objectInterface = findObjectInterface(ejbDescriptor.getLocalBusinessInterfaces()); removeMethodSignatures = new ArrayList<MethodSignature>(); if (ejbDescriptor.getRemoveMethods() != null) { for (Method method : ejbDescriptor.getRemoveMethods()) { removeMethodSignatures.add(new MethodSignatureImpl(method)); } } this.localBusinessInterfaces = transformToClasses(getLocalBusinessInterfaces()); this.remoteBusinessInterfaces = transformToClasses(getRemoteBusinessInterfaces()); }
private InternalEjbDescriptor(EjbDescriptor<T> ejbDescriptor) { this.delegate = ejbDescriptor; this.objectInterface = findObjectInterface(ejbDescriptor.getLocalBusinessInterfaces()); removeMethodSignatures = new ArrayList<MethodSignature>(); if (ejbDescriptor.getRemoveMethods() != null) { for (Method method : ejbDescriptor.getRemoveMethods()) { removeMethodSignatures.add(new MethodSignatureImpl(method)); } } this.localBusinessInterfaces = transformToClasses(getLocalBusinessInterfaces()); this.remoteBusinessInterfaces = transformToClasses(getRemoteBusinessInterfaces()); }
for (Method method : AccessController.doPrivileged(new GetDeclaredMethodsAction(cls))) { final MethodSignatureImpl methodSignature = new MethodSignatureImpl(method); MethodSignature signature = new MethodSignatureImpl(method);
/** * Constructor * <p/> * Initializes the superclass with the built annotation map, sets the method * and declaring class abstraction and detects the actual type arguments * * @param method The underlying method * @param declaringClass The declaring class abstraction */ private EnhancedAnnotatedMethodImpl(AnnotatedMethod<X> annotatedMethod, Map<Class<? extends Annotation>, Annotation> annotationMap, Map<Class<? extends Annotation>, Annotation> declaredAnnotationMap, EnhancedAnnotatedType<X> declaringClass, ClassTransformer classTransformer) { super(annotatedMethod, annotationMap, declaredAnnotationMap, classTransformer, declaringClass); this.slim = annotatedMethod; ArrayList<EnhancedAnnotatedParameter<?, X>> parameters = new ArrayList<EnhancedAnnotatedParameter<?, X>>(annotatedMethod.getParameters().size()); validateParameterCount(annotatedMethod); for (AnnotatedParameter<X> annotatedParameter : annotatedMethod.getParameters()) { EnhancedAnnotatedParameter<?, X> parameter = EnhancedAnnotatedParameterImpl.of(annotatedParameter, this, classTransformer); parameters.add(parameter); } this.parameters = immutableListView(parameters); String propertyName = Reflections.getPropertyName(getDelegate()); if (propertyName == null) { this.propertyName = getName(); } else { this.propertyName = propertyName; } this.signature = new MethodSignatureImpl(this); }
/** * Constructor * <p/> * Initializes the superclass with the built annotation map, sets the method * and declaring class abstraction and detects the actual type arguments * * @param method The underlying method * @param declaringClass The declaring class abstraction */ private EnhancedAnnotatedMethodImpl(AnnotatedMethod<X> annotatedMethod, Map<Class<? extends Annotation>, Annotation> annotationMap, Map<Class<? extends Annotation>, Annotation> declaredAnnotationMap, EnhancedAnnotatedType<X> declaringClass, ClassTransformer classTransformer) { super(annotatedMethod, annotationMap, declaredAnnotationMap, classTransformer, declaringClass); this.slim = annotatedMethod; ArrayList<EnhancedAnnotatedParameter<?, X>> parameters = new ArrayList<EnhancedAnnotatedParameter<?, X>>(annotatedMethod.getParameters().size()); validateParameterCount(annotatedMethod); for (AnnotatedParameter<X> annotatedParameter : annotatedMethod.getParameters()) { EnhancedAnnotatedParameter<?, X> parameter = EnhancedAnnotatedParameterImpl.of(annotatedParameter, this, classTransformer); parameters.add(parameter); } this.parameters = immutableListView(parameters); String propertyName = Reflections.getPropertyName(getDelegate()); if (propertyName == null) { this.propertyName = getName(); } else { this.propertyName = propertyName; } this.signature = new MethodSignatureImpl(this); }
/** * Constructor * <p/> * Initializes the superclass with the built annotation map, sets the method * and declaring class abstraction and detects the actual type arguments * * @param method The underlying method * @param declaringClass The declaring class abstraction */ private EnhancedAnnotatedMethodImpl(AnnotatedMethod<X> annotatedMethod, Map<Class<? extends Annotation>, Annotation> annotationMap, Map<Class<? extends Annotation>, Annotation> declaredAnnotationMap, EnhancedAnnotatedType<X> declaringClass, ClassTransformer classTransformer) { super(annotatedMethod, annotationMap, declaredAnnotationMap, classTransformer, declaringClass); this.slim = annotatedMethod; ArrayList<EnhancedAnnotatedParameter<?, X>> parameters = new ArrayList<EnhancedAnnotatedParameter<?, X>>(annotatedMethod.getParameters().size()); validateParameterCount(annotatedMethod); for (AnnotatedParameter<X> annotatedParameter : annotatedMethod.getParameters()) { EnhancedAnnotatedParameter<?, X> parameter = EnhancedAnnotatedParameterImpl.of(annotatedParameter, this, classTransformer); parameters.add(parameter); } this.parameters = immutableListView(parameters); String propertyName = Reflections.getPropertyName(getDelegate()); if (propertyName == null) { this.propertyName = getName(); } else { this.propertyName = propertyName; } this.signature = new MethodSignatureImpl(this); }
/** * Constructor * <p/> * Initializes the superclass with the built annotation map, sets the method * and declaring class abstraction and detects the actual type arguments * * @param method The underlying method * @param declaringClass The declaring class abstraction */ private EnhancedAnnotatedMethodImpl(AnnotatedMethod<X> annotatedMethod, Map<Class<? extends Annotation>, Annotation> annotationMap, Map<Class<? extends Annotation>, Annotation> declaredAnnotationMap, EnhancedAnnotatedType<X> declaringClass, ClassTransformer classTransformer) { super(annotatedMethod, annotationMap, declaredAnnotationMap, classTransformer, declaringClass); this.slim = annotatedMethod; ArrayList<EnhancedAnnotatedParameter<?, X>> parameters = new ArrayList<EnhancedAnnotatedParameter<?, X>>(annotatedMethod.getParameters().size()); validateParameterCount(annotatedMethod); for (AnnotatedParameter<X> annotatedParameter : annotatedMethod.getParameters()) { EnhancedAnnotatedParameter<?, X> parameter = EnhancedAnnotatedParameterImpl.of(annotatedParameter, this, classTransformer); parameters.add(parameter); } this.parameters = immutableListView(parameters); String propertyName = Reflections.getPropertyName(getDelegate()); if (propertyName == null) { this.propertyName = getName(); } else { this.propertyName = propertyName; } this.signature = new MethodSignatureImpl(this); }
/** * Constructor * <p/> * Initializes the superclass with the built annotation map, sets the method * and declaring class abstraction and detects the actual type arguments * * @param method The underlying method * @param declaringClass The declaring class abstraction */ private EnhancedAnnotatedMethodImpl(AnnotatedMethod<X> annotatedMethod, Map<Class<? extends Annotation>, Annotation> annotationMap, Map<Class<? extends Annotation>, Annotation> declaredAnnotationMap, EnhancedAnnotatedType<X> declaringClass, ClassTransformer classTransformer) { super(annotatedMethod, annotationMap, declaredAnnotationMap, classTransformer, declaringClass); this.slim = annotatedMethod; ArrayList<EnhancedAnnotatedParameter<?, X>> parameters = new ArrayList<EnhancedAnnotatedParameter<?, X>>(annotatedMethod.getParameters().size()); validateParameterCount(annotatedMethod); for (AnnotatedParameter<X> annotatedParameter : annotatedMethod.getParameters()) { EnhancedAnnotatedParameter<?, X> parameter = EnhancedAnnotatedParameterImpl.of(annotatedParameter, this, classTransformer); parameters.add(parameter); } this.parameters = immutableListView(parameters); String propertyName = Reflections.getPropertyName(getDelegate()); if (propertyName == null) { this.propertyName = getName(); } else { this.propertyName = propertyName; } this.signature = new MethodSignatureImpl(this); }
/** * Constructor * <p/> * Initializes the superclass with the built annotation map, sets the method * and declaring class abstraction and detects the actual type arguments * * @param method The underlying method * @param declaringClass The declaring class abstraction */ private EnhancedAnnotatedMethodImpl(AnnotatedMethod<X> annotatedMethod, Map<Class<? extends Annotation>, Annotation> annotationMap, Map<Class<? extends Annotation>, Annotation> declaredAnnotationMap, EnhancedAnnotatedType<X> declaringClass, ClassTransformer classTransformer) { super(annotatedMethod, annotationMap, declaredAnnotationMap, classTransformer, declaringClass); this.slim = annotatedMethod; ArrayList<EnhancedAnnotatedParameter<?, X>> parameters = new ArrayList<EnhancedAnnotatedParameter<?, X>>(annotatedMethod.getParameters().size()); validateParameterCount(annotatedMethod); for (AnnotatedParameter<X> annotatedParameter : annotatedMethod.getParameters()) { EnhancedAnnotatedParameter<?, X> parameter = EnhancedAnnotatedParameterImpl.of(annotatedParameter, this, classTransformer); parameters.add(parameter); } this.parameters = immutableListView(parameters); String propertyName = Reflections.getPropertyName(getDelegate()); if (propertyName == null) { this.propertyName = getName(); } else { this.propertyName = propertyName; } this.signature = new MethodSignatureImpl(this); }