public class ParserAnnotation extends ParseBase
Modifier and Type | Class and Description |
---|---|
(package private) static class |
ParserAnnotation.AnnotationElemValue
AnnotationElemValue
Used to store Annotation values
|
(package private) static class |
ParserAnnotation.ArrayElemValue
ArrayElemValue
Annotation Element value referring to an Array
|
(package private) static class |
ParserAnnotation.ClassElemValue
ClassElemValue
Annotation Element value referring to a class
|
(package private) static class |
ParserAnnotation.ConstElemValue
ConstElemValue
Annotation Element value referring to a Constant
|
(package private) static class |
ParserAnnotation.EnumElemValue
EnumElemValue
Element Value for Enums
|
private static class |
ParserAnnotation.TTVis
TTVis
Target Type visitor, used for constructing the target-info within a type
annotation.
|
Modifier and Type | Field and Description |
---|---|
private static ParserAnnotation.TTVis |
ttVisitor
local handles on the scanner, main parser, and the error reporting env
|
Modifier | Constructor and Description |
---|---|
protected |
ParserAnnotation(Scanner scanner,
Parser parser,
Environment env) |
Modifier and Type | Method and Description |
---|---|
private void |
_scanAnnotation(AnnotationData annotData)
_scanAnnotation
parses an individual annotation-data.
|
private void |
_scanTargetPath(TypeAnnotationData annotData)
_scanTargetPath
parses and fills the type_path structure (4.7.20.2)
type_path {
u1 path_length;
{ u1 type_path_kind;
u1 type_argument_index;
} path[path_length];
}
|
private TypeAnnotationTypes.TypePathEntry |
_scanTypePathEntry()
_scanTypeLocation
parses a path entry of the type_path.
|
private void |
_scanTypeTarget(TypeAnnotationData annotData)
_scanAnnotation
parses an individual annotation-data.
|
private AnnotationData |
parseAnnotation()
scanAnnotation
parses an individual annotation.
|
protected DefaultAnnotationAttr |
parseDefaultAnnotation()
parseDefaultAnnotation
parses a default Annotation attribute
|
protected void |
parseParamAnnots(int _totalParams,
MethodData curMethod)
parseParamAnnots
Parses Parameter Annotations attributes.
|
private AnnotationData |
parseTypeAnnotation()
parseTypeAnnotation
parses an individual annotation.
|
private ParserAnnotation.ArrayElemValue |
scanAnnotationArray(java.lang.String name)
scanAnnotationArray
Scans an Array of annotations.
|
private Data |
scanAnnotationClass(java.lang.String name)
scanAnnotationEnum
Scans an annotation enum val.
|
private Data |
scanAnnotationData(java.lang.String name)
scanAnnotationData
parses the internals of an annotation.
|
private ParserAnnotation.EnumElemValue |
scanAnnotationEnum(java.lang.String name)
scanAnnotationEnum
Scans an annotation enum val.
|
private Data |
scanAnnotationIdent(java.lang.String ident,
java.lang.String name)
scanAnnotationIdent
parses the identifier of an annotation.
|
(package private) java.util.ArrayList<AnnotationData> |
scanAnnotations()
The main entry for parsing an annotation list.
|
protected void |
scanParamName(int totalParams,
int paramNum,
MethodData curMethod) |
debugScan, debugStr, enableDebug, init
private static ParserAnnotation.TTVis ttVisitor
protected ParserAnnotation(Scanner scanner, Parser parser, Environment env)
protected void scanParamName(int totalParams, int paramNum, MethodData curMethod) throws java.io.IOException
java.io.IOException
java.util.ArrayList<AnnotationData> scanAnnotations() throws java.io.IOException
java.io.IOException
protected DefaultAnnotationAttr parseDefaultAnnotation() throws Scanner.SyntaxError, java.io.IOException
Scanner.SyntaxError
java.io.IOException
protected void parseParamAnnots(int _totalParams, MethodData curMethod) throws Scanner.SyntaxError, java.io.IOException
_totalParams
- curMethod
- Scanner.SyntaxError
java.io.IOException
private AnnotationData parseTypeAnnotation() throws Scanner.SyntaxError, java.io.IOException
java.io.IOException
Scanner.SyntaxError
private AnnotationData parseAnnotation() throws Scanner.SyntaxError, java.io.IOException
java.io.IOException
Scanner.SyntaxError
private void _scanAnnotation(AnnotationData annotData) throws Scanner.SyntaxError, java.io.IOException
java.io.IOException
Scanner.SyntaxError
private void _scanTypeTarget(TypeAnnotationData annotData) throws Scanner.SyntaxError, java.io.IOException
java.io.IOException
Scanner.SyntaxError
private void _scanTargetPath(TypeAnnotationData annotData) throws Scanner.SyntaxError, java.io.IOException
Scanner.SyntaxError,
- IOExceptionScanner.SyntaxError
java.io.IOException
private TypeAnnotationTypes.TypePathEntry _scanTypePathEntry() throws Scanner.SyntaxError, java.io.IOException
Scanner.SyntaxError,
- IOExceptionScanner.SyntaxError
java.io.IOException
private ParserAnnotation.ArrayElemValue scanAnnotationArray(java.lang.String name) throws java.io.IOException
name
- Name of the annotationjava.io.IOException
- if scanning errors existprivate Data scanAnnotationClass(java.lang.String name) throws java.io.IOException
name
- Annotation Namejava.io.IOException
private ParserAnnotation.EnumElemValue scanAnnotationEnum(java.lang.String name) throws java.io.IOException
name
- Annotation Namejava.io.IOException
- for scanning errors.private Data scanAnnotationData(java.lang.String name) throws java.io.IOException
name
- Annotation Namejava.io.IOException
- for scanning errors.private Data scanAnnotationIdent(java.lang.String ident, java.lang.String name) throws java.io.IOException
ident
- Basic Type identifiername
- Annotation Namejava.io.IOException
- if scanning errors occur