Class ServiceProcessor
- java.lang.Object
-
- javax.annotation.processing.AbstractProcessor
-
- org.glassfish.hk2.metadata.generator.ServiceProcessor
-
- All Implemented Interfaces:
javax.annotation.processing.Processor
@SupportedAnnotationTypes("org.jvnet.hk2.annotations.Service") @SupportedOptions("org.glassfish.hk2.metadata.location") public class ServiceProcessor extends javax.annotation.processing.AbstractProcessor
The entry point for service @Service annotations
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description private static class
ServiceProcessor.DescriptorComparitor
This is a comparator making things that don't really compare, compare.
-
Field Summary
Fields Modifier and Type Field Description private java.util.TreeSet<DescriptorImpl>
allDescriptors
private static java.lang.String
LOCATION_DEFAULT
private static java.lang.String
LOCATION_OPTION
private java.util.ArrayList<javax.lang.model.element.Element>
originators
-
Constructor Summary
Constructors Constructor Description ServiceProcessor()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description private void
createFile()
javax.lang.model.SourceVersion
getSupportedSourceVersion()
Gets rid of warnings and this code should work with all source versionsboolean
process(java.util.Set<? extends javax.lang.model.element.TypeElement> annotations, javax.annotation.processing.RoundEnvironment roundEnv)
-
-
-
Field Detail
-
LOCATION_OPTION
private static final java.lang.String LOCATION_OPTION
- See Also:
- Constant Field Values
-
LOCATION_DEFAULT
private static final java.lang.String LOCATION_DEFAULT
- See Also:
- Constant Field Values
-
allDescriptors
private final java.util.TreeSet<DescriptorImpl> allDescriptors
-
originators
private final java.util.ArrayList<javax.lang.model.element.Element> originators
-
-
Method Detail
-
process
public boolean process(java.util.Set<? extends javax.lang.model.element.TypeElement> annotations, javax.annotation.processing.RoundEnvironment roundEnv)
- Specified by:
process
in interfacejavax.annotation.processing.Processor
- Specified by:
process
in classjavax.annotation.processing.AbstractProcessor
-
getSupportedSourceVersion
public javax.lang.model.SourceVersion getSupportedSourceVersion()
Gets rid of warnings and this code should work with all source versions- Specified by:
getSupportedSourceVersion
in interfacejavax.annotation.processing.Processor
- Overrides:
getSupportedSourceVersion
in classjavax.annotation.processing.AbstractProcessor
-
createFile
private void createFile() throws java.io.IOException
- Throws:
java.io.IOException
-
-