|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectde.upb.swt.mcie.parser.token.Token
de.upb.swt.mcie.parser.token.Brack
public class Brack
Implements the token for brackets. Whether it is an opening or
a closing bracket is defined by its type
. Moreover,
there can be different versions of brackets version
.
Field Summary | |
---|---|
static int |
BRACE
The code for a brace. |
static int |
CLOSE
The code for a closing bracket. |
static int |
NORMAL
The code for a normal bracket (parenthesis). |
static int |
OPEN
The code for an opening bracket. |
static int |
SQUARE
The code for a square bracket. |
private int |
type
The type of the bracket. |
private int |
version
The version of this bracket. |
Constructor Summary | |
---|---|
Brack(int type,
int version)
Creates a token for a bracket with the corresponding type and version. |
Method Summary | |
---|---|
int |
getType()
Returns the type of the bracket. |
int |
getVersion()
Returns the version of the bracket. |
Methods inherited from class de.upb.swt.mcie.parser.token.Token |
---|
setReference, toString |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final int OPEN
public static final int CLOSE
public static final int NORMAL
public static final int SQUARE
public static final int BRACE
private int type
private int version
Constructor Detail |
---|
public Brack(int type, int version)
type
- the type of the bracket OPEN
or CLOSE
version
- the versionMethod Detail |
---|
public int getType()
public int getVersion()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |