Package me.gilbva.shrike.processor
Class ComponentProcessor
java.lang.Object
javax.annotation.processing.AbstractProcessor
me.gilbva.shrike.utils.ClassListPropertyFile
me.gilbva.shrike.processor.ComponentProcessor
- All Implemented Interfaces:
javax.annotation.processing.Processor
@SupportedAnnotationTypes("me.gilbva.shrike.annotations.Component")
@SupportedSourceVersion(RELEASE_11)
public class ComponentProcessor
extends ClassListPropertyFile
Annotations processor for the
Component annotation.- Author:
- Gilberto Vento
-
Field Summary
-
Constructor Summary
Constructors Constructor Description ComponentProcessor() -
Method Summary
Modifier and Type Method Description java.lang.StringgetFileName()Gets the name for the file that will be written by this annotation processor.voidprocessElement(javax.lang.model.element.Element element)This method will be called for each component class found by this processor.Methods inherited from class me.gilbva.shrike.utils.ClassListPropertyFile
appendProperty, init, process
-
Constructor Details
-
ComponentProcessor
public ComponentProcessor()
-
-
Method Details
-
getFileName
public java.lang.String getFileName()Description copied from class:ClassListPropertyFileGets the name for the file that will be written by this annotation processor.- Specified by:
getFileNamein classClassListPropertyFile- Returns:
- The name of the file for this annotation processor.
-
processElement
public void processElement(javax.lang.model.element.Element element) throws java.io.IOExceptionDescription copied from class:ClassListPropertyFileThis method will be called for each component class found by this processor. the implementation of this method must call the appendClass method to write the component reference to de file.- Specified by:
processElementin classClassListPropertyFile- Parameters:
element- The element representing the current component class.- Throws:
java.io.IOException- If the component cannot be written to the file.
-