protected ServiceReferenceMetaData createServiceRef(WebServiceRef annotation, E element) { ServiceReferenceMetaData ref = new ServiceReferenceMetaData(); String name = annotation.name(); if (name.length() == 0) name = getName(element); ref.setServiceRefName(name); if (annotation.mappedName().length() > 0) ref.setMappedName(annotation.mappedName()); ref.setAnnotatedElement(element); if (annotation.wsdlLocation().length() > 0) ref.setWsdlFile(annotation.wsdlLocation()); if (annotation.type() != Object.class) { ref.setServiceRefType(annotation.type().getName()); } else ref.setServiceRefType(getType(element)); if (annotation.value() != Service.class) { ref.setServiceInterface(annotation.value().getName()); } else if (element instanceof Field) { final Class<?> targetClass = ((Field) element).getType(); if (Service.class.isAssignableFrom(targetClass)) ref.setServiceInterface(targetClass.getName()); } else if (element instanceof Method) { final Class<?> targetClass = ((Method) element).getParameterTypes()[0]; if (Service.class.isAssignableFrom(targetClass)) ref.setServiceInterface(targetClass.getName()); } else { ref.setServiceInterface(Service.class.getName()); } String injectionName = getInjectionName(element); Set<ResourceInjectionTargetMetaData> injectionTargets = ProcessorUtils.getInjectionTargets(injectionName, element); if (injectionTargets != null) ref.setInjectionTargets(injectionTargets); return ref; }
public Collection<Class<? extends Annotation>> getAnnotationTypes() { return ProcessorUtils.createAnnotationSet(WebServiceRef.class); }
public Collection<Class<? extends Annotation>> getAnnotationTypes() { return ProcessorUtils.createAnnotationSet(LocalHomeBinding.class); }