Package org.tentackle.buildsupport
Class BundleAnalyzeHandler
java.lang.Object
org.tentackle.buildsupport.AbstractAnalyzeHandler
org.tentackle.buildsupport.BundleAnalyzeHandler
- All Implemented Interfaces:
AnalyzeHandler
- Direct Known Subclasses:
FxControllerBundleAnalyzeHandler
Handler to extract the name of the resource bundle from
the class annotated with
@Bundle.- Author:
- harald
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected StringgetBundleName(Element element, String annotationName) Gets the bundlename from the annotated element.Gets the annotation processor.voidprocessAnnotation(TypeElement annotationType, RoundEnvironment roundEnv) Processes the annotation.voidsetProcessor(AnalyzeProcessor processor) Sets the annotation processor.protected StringxlateBundleName(String bundleName) Translates the bundle name to a standard format.Methods inherited from class org.tentackle.buildsupport.AbstractAnalyzeHandler
getDirectory, print
-
Constructor Details
-
BundleAnalyzeHandler
public BundleAnalyzeHandler()
-
-
Method Details
-
setProcessor
Description copied from interface:AnalyzeHandlerSets the annotation processor.- Parameters:
processor- the annotation processor
-
getProcessor
Description copied from interface:AnalyzeHandlerGets the annotation processor.- Returns:
- the annotation processor
-
processAnnotation
Description copied from interface:AnalyzeHandlerProcesses the annotation.- Parameters:
annotationType- the annotation typeroundEnv- the processing environment
-
getBundleName
Gets the bundlename from the annotated element.- Parameters:
element- the bundle nameannotationName- the annotation name (e.g. ...Bundle)- Returns:
- the bundle name, null if no bundle
-
xlateBundleName
Translates the bundle name to a standard format.- Parameters:
bundleName- the name- Returns:
- the standardized name in dot format (without .class)
-