|
Venice 0.7beta | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.mov.parser.Token
public class Token
A representation of any token in the Gondola language.
| Field Summary | |
|---|---|
static int |
ABS_TOKEN
Represents " abs" symbol |
static int |
ADD_TOKEN
Represents " +" symbol |
static int |
AND_TOKEN
Represents " and" symbol |
static int |
AVG_TOKEN
Represents " avg" symbol |
static int |
BBL_TOKEN
Represents " bol_lower()" symbol |
static int |
BBU_TOKEN
Represents " bol_upper()" symbol |
static int |
BOOLEAN_TOKEN
Represents " boolean" symbol |
static int |
COMMA_TOKEN
Represents " ," symbol |
static int |
CONSTANT_TOKEN
Represents " const" symbol |
static int |
CORR_TOKEN
Represents " corr()" symbol |
static int |
COS_TOKEN
Represents " cos()" symbol |
static int |
DAY_CLOSE_TOKEN
Represents " close" symbol |
static int |
DAY_HIGH_TOKEN
Represents " high" symbol |
static int |
DAY_LOW_TOKEN
Represents " low" symbol |
static int |
DAY_OF_WEEK_TOKEN
Represents " dayofweek()" symbol |
static int |
DAY_OF_YEAR_TOKEN
Represents " dayofyear()" symbol |
static int |
DAY_OPEN_TOKEN
Represents " open" symbol |
static int |
DAY_TOKEN
Represents " day()" symbol |
static int |
DAY_VOLUME_TOKEN
Represents " volume" symbol |
static int |
DIVIDE_TOKEN
Represents " /" symbol |
static int |
ELSE_TOKEN
Represents " else" symbol |
static int |
EMA_TOKEN
Represents " ema()" symbol |
static int |
EQUAL_TOKEN
Represents " ==" symbol |
static int |
EXP_TOKEN
Represents " exp()" symbol |
static int |
FALSE_TOKEN
Represents " false" symbol |
static int |
FLOAT_TOKEN
Represents " float" symbol |
static int |
FOR_TOKEN
Represents " flor" symbol |
static int |
FULLSTOP_TOKEN
Represents " . |
static int |
GREATER_THAN_EQUAL_TOKEN
Represents " >=" symbol |
static int |
GREATER_THAN_TOKEN
Represents " >" symbol |
static int |
IF_TOKEN
Represents " if" symbol |
static int |
INTEGER_TOKEN
Represents " int" symbol |
static int |
LAG_TOKEN
Represents " lag" symbol |
static int |
LEFT_BRACE_TOKEN
Represents " {" symbol |
static int |
LEFT_PARENTHESIS_TOKEN
Represents " (" symbol |
static int |
LESS_THAN_EQUAL_TOKEN
Represents " <=" symbol |
static int |
LESS_THAN_TOKEN
Represents " <" symbol |
static int |
LOG_TOKEN
Represents " log()" symbol |
static int |
MACD_TOKEN
Represents " macd()" symbol |
static int |
MAX_TOKEN
Represents " max" symbol |
static int |
MIN_TOKEN
Represents " min" symbol |
static int |
MOMENTUM_TOKEN
Represents " momentum()" symbol |
static int |
MONTH_TOKEN
Represents " month()" symbol |
static int |
MULTIPLY_TOKEN
Represents " *" symbol |
static int |
NOT_EQUAL_TOKEN
Represents " ! |
static int |
NOT_TOKEN
Represents " not" symbol |
static int |
NUMBER_TOKEN
Represents a number symbol |
static int |
OBV_TOKEN
Represents " obv()" symbol |
static int |
OR_TOKEN
Represents " or" symbol |
static int |
PERCENT_TOKEN
Represents " percent" symbol |
static int |
RIGHT_BRACE_TOKEN
Represents " }" symbol |
static int |
RIGHT_PARENTHESIS_TOKEN
Represents " )" symbol |
static int |
RSI_TOKEN
Represents " rsi" symbol |
static int |
SD_TOKEN
Represents " sd()" symbol |
static int |
SEMICOLON_TOKEN
Represents " ;" symbol |
static int |
SET_TOKEN
Represents " =" symbol |
static int |
SIN_TOKEN
Represents " sin()" symbol |
static int |
SQRT_TOKEN
Represents " sqrt" symbol |
static int |
STRING_TOKEN
Represents a string |
static int |
SUBTRACT_TOKEN
Represents " -" symbol |
static int |
SUM_TOKEN
Represents " sum" symbol |
static int |
TREND_TOKEN
Represents " trend()" symbol |
static int |
TRUE_TOKEN
Represents " true" symbol |
static int |
VARIABLE_TOKEN
Represents a variable |
static int |
WHILE_TOKEN
Represents " while" symbol |
static int |
YEAR_TOKEN
Represents " year()" symbol |
| Constructor Summary | |
|---|---|
Token()
Create a new empty token. |
|
| Method Summary | |
|---|---|
java.lang.String |
getStringValue()
For string tokens, get the value. |
int |
getType()
Get the type of this token. |
double |
getValue()
For number tokens, get the value. |
int |
getValueType()
For NUMBER_TOKEN get the type. |
java.lang.String |
getVariableName()
For variable token, get the name. |
void |
negate()
For NUMBER_TOKEN, negate the value. |
void |
setType(int type)
Set the type of this token. |
static java.lang.String |
stringToToken(Variables variables,
Token token,
java.lang.String string)
Perform lexical analysis on the given string. |
static java.lang.String[] |
wordsOfGondola()
Return a string containing all the words of Gondola language. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final int LEFT_PARENTHESIS_TOKEN
(" symbol
public static final int RIGHT_PARENTHESIS_TOKEN
)" symbol
public static final int LESS_THAN_EQUAL_TOKEN
<=" symbol
public static final int GREATER_THAN_EQUAL_TOKEN
>=" symbol
public static final int LESS_THAN_TOKEN
<" symbol
public static final int GREATER_THAN_TOKEN
>" symbol
public static final int EQUAL_TOKEN
==" symbol
public static final int ADD_TOKEN
+" symbol
public static final int SUBTRACT_TOKEN
-" symbol
public static final int MULTIPLY_TOKEN
*" symbol
public static final int DIVIDE_TOKEN
/" symbol
public static final int OR_TOKEN
or" symbol
public static final int AND_TOKEN
and" symbol
public static final int NOT_TOKEN
not" symbol
public static final int COMMA_TOKEN
," symbol
public static final int LAG_TOKEN
lag" symbol
public static final int MIN_TOKEN
min" symbol
public static final int MAX_TOKEN
max" symbol
public static final int AVG_TOKEN
avg" symbol
public static final int DAY_OPEN_TOKEN
open" symbol
public static final int DAY_CLOSE_TOKEN
close" symbol
public static final int DAY_LOW_TOKEN
low" symbol
public static final int DAY_HIGH_TOKEN
high" symbol
public static final int DAY_VOLUME_TOKEN
volume" symbol
public static final int IF_TOKEN
if" symbol
public static final int LEFT_BRACE_TOKEN
{" symbol
public static final int RIGHT_BRACE_TOKEN
}" symbol
public static final int FULLSTOP_TOKEN
." symbol
public static final int ELSE_TOKEN
else" symbol
public static final int PERCENT_TOKEN
percent" symbol
public static final int NOT_EQUAL_TOKEN
!=" symbol
public static final int RSI_TOKEN
rsi" symbol
public static final int TRUE_TOKEN
true" symbol
public static final int FALSE_TOKEN
false" symbol
public static final int DAY_OF_WEEK_TOKEN
dayofweek()" symbol
public static final int DAY_OF_YEAR_TOKEN
dayofyear()" symbol
public static final int DAY_TOKEN
day()" symbol
public static final int MONTH_TOKEN
month()" symbol
public static final int YEAR_TOKEN
year()" symbol
public static final int SUM_TOKEN
sum" symbol
public static final int SQRT_TOKEN
sqrt" symbol
public static final int ABS_TOKEN
abs" symbol
public static final int CONSTANT_TOKEN
const" symbol
public static final int BOOLEAN_TOKEN
boolean" symbol
public static final int INTEGER_TOKEN
int" symbol
public static final int FLOAT_TOKEN
float" symbol
public static final int SET_TOKEN
=" symbol
public static final int SEMICOLON_TOKEN
;" symbol
public static final int FOR_TOKEN
flor" symbol
public static final int WHILE_TOKEN
while" symbol
public static final int CORR_TOKEN
corr()" symbol
public static final int EMA_TOKEN
ema()" symbol
public static final int BBL_TOKEN
bol_lower()" symbol
public static final int BBU_TOKEN
bol_upper()" symbol
public static final int MACD_TOKEN
macd()" symbol
public static final int MOMENTUM_TOKEN
momentum()" symbol
public static final int OBV_TOKEN
obv()" symbol
public static final int SD_TOKEN
sd()" symbol
public static final int SIN_TOKEN
sin()" symbol
public static final int COS_TOKEN
cos()" symbol
public static final int LOG_TOKEN
log()" symbol
public static final int EXP_TOKEN
exp()" symbol
public static final int TREND_TOKEN
trend()" symbol
public static final int NUMBER_TOKEN
public static final int VARIABLE_TOKEN
public static final int STRING_TOKEN
| Constructor Detail |
|---|
public Token()
| Method Detail |
|---|
public static java.lang.String[] wordsOfGondola()
public static java.lang.String stringToToken(Variables variables,
Token token,
java.lang.String string)
throws ParserException
variables - variables that will be assumed to be defined
for the equationtoken - the token to use to represent the first symbol foundstring - the string to extract the first symbol from
ParserExceptionpublic int getType()
public void setType(int type)
type - the new typepublic double getValue()
public java.lang.String getStringValue()
public java.lang.String getVariableName()
public int getValueType()
NUMBER_TOKEN get the type.
public void negate()
NUMBER_TOKEN, negate the value.
|
Venice 0.7beta | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||