Class ProtoParser
java.lang.Object
org.fusesource.hawtbuf.proto.compiler.parser.ProtoParser
- All Implemented Interfaces:
ProtoParserConstants
This class is generated with JavaCC. Do not modify manually.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescription(package private) static final classprivate static final class -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final ProtoParser.JJCalls[]private intprivate List<int[]> private int[]private intprivate int(package private) SimpleCharStreamprivate intprivate intprivate final int[]private static int[]private static int[]private Tokenprivate int[]private static final ProtoParser.LookaheadSuccessNext token.private intprivate booleanprivate TokenCurrent token.Generated Token Manager.private booleanFields inherited from interface ProtoParserConstants
COMMA, COMMENT, DECIMAL_LITERAL, DEFAULT, ENUM, EOF, EQUALS, EXPONENT, EXTEND, EXTENSIONS, FLOAT, GROUP, HEX_LITERAL, ID, IMPORT, INTEGER, LBRACE, LBRACKET, LPAREN, MAX, MESSAGE, OCTAL_LITERAL, OPTION, OPTIONAL, PACKAGE, PERIOD, RBRACE, RBRACKET, REPEATED, REQURIED, RETURNS, RPAREN, RPC, SEMICOLON, SERVICE, STRING, TO, tokenImage -
Constructor Summary
ConstructorsConstructorDescriptionProtoParser(InputStream stream) Constructor with InputStream.ProtoParser(InputStream stream, String encoding) Constructor with InputStream and supplied encodingProtoParser(Reader stream) Constructor.Constructor with generated Token Manager. -
Method Summary
Modifier and TypeMethodDescriptionfinal voidDisable tracing.final voidEnable tracing.final EnumDescriptorEnumDescriptor(ProtoDescriptor proto, MessageDescriptor parent) final EnumFieldDescriptorEnumFieldDescriptor(EnumDescriptor parent) Parses something like: optional string foo = 1;final MessageDescriptorExtendDescriptor(ProtoDescriptor proto, MessageDescriptor parent) final ExtensionsDescriptorfinal FieldDescriptorFieldDescriptor(MessageDescriptor parent) Parses something like: optional string foo = 1;Generate ParseException.final TokenGet the next Token.final TokengetToken(int index) Get the specific Token.final StringID()final intInteger()private booleanjj_2_1(int xla) private booleanjj_2_2(int xla) private booleanjj_3_1()private booleanjj_3_2()private booleanprivate booleanprivate booleanprivate booleanprivate booleanprivate booleanprivate voidjj_add_error_token(int kind, int pos) private Tokenjj_consume_token(int kind) private static voidprivate static voidprivate intjj_ntk_f()private voidprivate voidjj_save(int index, int xla) private booleanjj_scan_token(int kind) final MessageDescriptorMessageDescriptor(ProtoDescriptor proto, MessageDescriptor parent) final MethodDescriptorMethodDescriptor(ProtoDescriptor proto) final OptionDescriptorfinal Stringfinal ProtoDescriptorvoidReInit(InputStream stream) Reinitialise.voidReInit(InputStream stream, String encoding) Reinitialise.voidReinitialise.voidReinitialise.final StringRule()final ServiceDescriptorServiceDescriptor(ProtoDescriptor proto) final Stringfinal booleanTrace enabled.final StringValue()
-
Field Details
-
token_source
Generated Token Manager. -
jj_input_stream
SimpleCharStream jj_input_stream -
token
Current token. -
jj_nt
Next token. -
jj_ntk
private int jj_ntk -
jj_scanpos
-
jj_lastpos
-
jj_la
private int jj_la -
jj_gen
private int jj_gen -
jj_la1
private final int[] jj_la1 -
jj_la1_0
private static int[] jj_la1_0 -
jj_la1_1
private static int[] jj_la1_1 -
jj_2_rtns
-
jj_rescan
private boolean jj_rescan -
jj_gc
private int jj_gc -
jj_ls
-
jj_expentries
-
jj_expentry
private int[] jj_expentry -
jj_kind
private int jj_kind -
jj_lasttokens
private int[] jj_lasttokens -
jj_endpos
private int jj_endpos -
trace_enabled
private boolean trace_enabled
-
-
Constructor Details
-
ProtoParser
Constructor with InputStream. -
ProtoParser
Constructor with InputStream and supplied encoding -
ProtoParser
Constructor. -
ProtoParser
Constructor with generated Token Manager.
-
-
Method Details
-
ProtoDescriptor
- Throws:
ParseException
-
MessageDescriptor
public final MessageDescriptor MessageDescriptor(ProtoDescriptor proto, MessageDescriptor parent) throws ParseException - Throws:
ParseException
-
FieldDescriptor
Parses something like: optional string foo = 1;- Throws:
ParseException
-
ServiceDescriptor
- Throws:
ParseException
-
MethodDescriptor
- Throws:
ParseException
-
OptionDescriptor
- Throws:
ParseException
-
ExtendDescriptor
public final MessageDescriptor ExtendDescriptor(ProtoDescriptor proto, MessageDescriptor parent) throws ParseException - Throws:
ParseException
-
ExtensionsDescriptor
public final ExtensionsDescriptor ExtensionsDescriptor(MessageDescriptor parent) throws ParseException - Throws:
ParseException
-
EnumDescriptor
public final EnumDescriptor EnumDescriptor(ProtoDescriptor proto, MessageDescriptor parent) throws ParseException - Throws:
ParseException
-
EnumFieldDescriptor
Parses something like: optional string foo = 1;- Throws:
ParseException
-
Integer
- Throws:
ParseException
-
Rule
- Throws:
ParseException
-
Value
- Throws:
ParseException
-
ID
- Throws:
ParseException
-
PackageID
- Throws:
ParseException
-
StringLitteral
- Throws:
ParseException
-
jj_2_1
private boolean jj_2_1(int xla) -
jj_2_2
private boolean jj_2_2(int xla) -
jj_3_1
private boolean jj_3_1() -
jj_3R_ID_540_5_10
private boolean jj_3R_ID_540_5_10() -
jj_3_2
private boolean jj_3_2() -
jj_3R_Integer_485_4_11
private boolean jj_3R_Integer_485_4_11() -
jj_3R_PackageID_576_7_14
private boolean jj_3R_PackageID_576_7_14() -
jj_3R_PackageID_570_2_9
private boolean jj_3R_PackageID_570_2_9() -
jj_3R_FieldDescriptor_278_7_12
private boolean jj_3R_FieldDescriptor_278_7_12() -
jj_3R_OptionDescriptor_372_5_13
private boolean jj_3R_OptionDescriptor_372_5_13() -
jj_la1_init_0
private static void jj_la1_init_0() -
jj_la1_init_1
private static void jj_la1_init_1() -
ReInit
Reinitialise. -
ReInit
Reinitialise. -
ReInit
Reinitialise. -
ReInit
Reinitialise. -
jj_consume_token
- Throws:
ParseException
-
jj_scan_token
private boolean jj_scan_token(int kind) -
getNextToken
Get the next Token. -
getToken
Get the specific Token. -
jj_ntk_f
private int jj_ntk_f() -
jj_add_error_token
private void jj_add_error_token(int kind, int pos) -
generateParseException
Generate ParseException. -
trace_enabled
public final boolean trace_enabled()Trace enabled. -
enable_tracing
public final void enable_tracing()Enable tracing. -
disable_tracing
public final void disable_tracing()Disable tracing. -
jj_rescan_token
private void jj_rescan_token() -
jj_save
private void jj_save(int index, int xla)
-