public TypeElement getWidgetType() { ThemeSupport themeSupportAnnotation = configurationTypeElement.getAnnotation(ThemeSupport.class); return AnnotationClassPropertyHarvester.getTypeOfClassProperty(themeSupportAnnotation, new AnnotationClassProperty<ThemeSupport>() { @Override public Class<?> getClassProperty(ThemeSupport annotation) { return annotation.widgetClass(); } }); }
protected void loadFromConfiguration() { Set<? extends Element> elementsAnnotatedWith = roundEnvironment.getElementsAnnotatedWith(ProcessorConfiguration.class); for (Element element: elementsAnnotatedWith) { ProcessorConfiguration configurationAnnotation = element.getAnnotation(ProcessorConfiguration.class); TypeElement processorClassType = AnnotationClassPropertyHarvester.getTypeOfClassProperty(configurationAnnotation, new AnnotationClassProperty<ProcessorConfiguration>(){ @Override public Class<?> getClassProperty(ProcessorConfiguration annotation) { return annotation.processor(); } }); if (this.processor.getClass().getName().equals(processorClassType.getQualifiedName().toString())) { configurations.add((TypeElement)element); } } for (TypeElement configurationType: configurations) { loadFromConfiguration(configurationType); } }
protected RemoteServiceTypeElement getRemoteServiceElement() { if (!isValid()) { return null; } LocalServiceDefinition localServiceDefinition = this.localServiceType.getAnnotation(LocalServiceDefinition.class); TypeElement remoteService = AnnotationClassPropertyHarvester.getTypeOfClassProperty(localServiceDefinition, new AnnotationClassProperty<LocalServiceDefinition>() { @Override public Class<?> getClassProperty(LocalServiceDefinition annotation) { return annotation.remoteService(); } }); return new RemoteServiceTypeElement(remoteService, this, processingEnv); }
ThemeSupport themeSupport = themeComponent.getAnnotation(ThemeSupport.class); TypeElement widgetClass = AnnotationClassPropertyHarvester.getTypeOfClassProperty(themeSupport, new AnnotationClassProperty<ThemeSupport>() {