Java Code Examples for com.google.javascript.rhino.Token#ERROR
The following examples show how to use
com.google.javascript.rhino.Token#ERROR .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: Reader.java From astor with GNU General Public License v2.0 | 6 votes |
/** * Returns count operator(++, --) associated with a specified name. */ private static int getNodeTypeForCountOp(String name) { Operator op = get(name); if (op == null) { return Token.ERROR; } int type; switch (op) { case DEC: type = Token.DEC; break; case INC: type = Token.INC; break; default: throw new IllegalArgumentException("" + "Invalid type of count expression."); } return type; }
Example 2
Source File: Cardumen_00200_t.java From coming with MIT License | 5 votes |
/** * Returns the inverse of an operator if it is invertible. * ex. '>' ==> '<' */ static int getInverseOperator(int type) { switch (type) { case Token.GT: return Token.LT; case Token.LT: return Token.GT; case Token.GE: return Token.LE; case Token.LE: return Token.GE; } return Token.ERROR; }
Example 3
Source File: NodeUtil.java From astor with GNU General Public License v2.0 | 5 votes |
/** * Returns the inverse of an operator if it is invertible. * ex. '>' ==> '<' */ static int getInverseOperator(int type) { switch (type) { case Token.GT: return Token.LT; case Token.LT: return Token.GT; case Token.GE: return Token.LE; case Token.LE: return Token.GE; } return Token.ERROR; }
Example 4
Source File: Closure_10_NodeUtil_s.java From coming with MIT License | 5 votes |
/** * Returns the inverse of an operator if it is invertible. * ex. '>' ==> '<' */ static int getInverseOperator(int type) { switch (type) { case Token.GT: return Token.LT; case Token.LT: return Token.GT; case Token.GE: return Token.LE; case Token.LE: return Token.GE; } return Token.ERROR; }
Example 5
Source File: Closure_10_NodeUtil_t.java From coming with MIT License | 5 votes |
/** * Returns the inverse of an operator if it is invertible. * ex. '>' ==> '<' */ static int getInverseOperator(int type) { switch (type) { case Token.GT: return Token.LT; case Token.LT: return Token.GT; case Token.GE: return Token.LE; case Token.LE: return Token.GE; } return Token.ERROR; }
Example 6
Source File: jMutRepair_003_t.java From coming with MIT License | 5 votes |
/** * Returns the inverse of an operator if it is invertible. * ex. '>' ==> '<' */ static int getInverseOperator(int type) { switch (type) { case Token.GT: return Token.LT; case Token.LT: return Token.GT; case Token.GE: return Token.LE; case Token.LE: return Token.GE; } return Token.ERROR; }
Example 7
Source File: jMutRepair_003_s.java From coming with MIT License | 5 votes |
/** * Returns the inverse of an operator if it is invertible. * ex. '>' ==> '<' */ static int getInverseOperator(int type) { switch (type) { case Token.GT: return Token.LT; case Token.LT: return Token.GT; case Token.GE: return Token.LE; case Token.LE: return Token.GE; } return Token.ERROR; }
Example 8
Source File: jKali_003_s.java From coming with MIT License | 5 votes |
/** * Returns the inverse of an operator if it is invertible. * ex. '>' ==> '<' */ static int getInverseOperator(int type) { switch (type) { case Token.GT: return Token.LT; case Token.LT: return Token.GT; case Token.GE: return Token.LE; case Token.LE: return Token.GE; } return Token.ERROR; }
Example 9
Source File: jKali_003_t.java From coming with MIT License | 5 votes |
/** * Returns the inverse of an operator if it is invertible. * ex. '>' ==> '<' */ static int getInverseOperator(int type) { switch (type) { case Token.GT: return Token.LT; case Token.LT: return Token.GT; case Token.GE: return Token.LE; case Token.LE: return Token.GE; } return Token.ERROR; }
Example 10
Source File: Cardumen_0087_t.java From coming with MIT License | 5 votes |
/** * Returns the inverse of an operator if it is invertible. * ex. '>' ==> '<' */ static int getInverseOperator(int type) { switch (type) { case Token.GT: return Token.LT; case Token.LT: return Token.GT; case Token.GE: return Token.LE; case Token.LE: return Token.GE; } return Token.ERROR; }
Example 11
Source File: Cardumen_0087_s.java From coming with MIT License | 5 votes |
/** * Returns the inverse of an operator if it is invertible. * ex. '>' ==> '<' */ static int getInverseOperator(int type) { switch (type) { case Token.GT: return Token.LT; case Token.LT: return Token.GT; case Token.GE: return Token.LE; case Token.LE: return Token.GE; } return Token.ERROR; }
Example 12
Source File: Cardumen_0014_s.java From coming with MIT License | 5 votes |
/** * Returns the inverse of an operator if it is invertible. * ex. '>' ==> '<' */ static int getInverseOperator(int type) { switch (type) { case Token.GT: return Token.LT; case Token.LT: return Token.GT; case Token.GE: return Token.LE; case Token.LE: return Token.GE; } return Token.ERROR; }
Example 13
Source File: Cardumen_0014_t.java From coming with MIT License | 5 votes |
/** * Returns the inverse of an operator if it is invertible. * ex. '>' ==> '<' */ static int getInverseOperator(int type) { switch (type) { case Token.GT: return Token.LT; case Token.LT: return Token.GT; case Token.GE: return Token.LE; case Token.LE: return Token.GE; } return Token.ERROR; }
Example 14
Source File: Cardumen_00149_t.java From coming with MIT License | 5 votes |
/** * Returns the inverse of an operator if it is invertible. * ex. '>' ==> '<' */ static int getInverseOperator(int type) { switch (type) { case Token.GT: return Token.LT; case Token.LT: return Token.GT; case Token.GE: return Token.LE; case Token.LE: return Token.GE; } return Token.ERROR; }
Example 15
Source File: Cardumen_00149_s.java From coming with MIT License | 5 votes |
/** * Returns the inverse of an operator if it is invertible. * ex. '>' ==> '<' */ static int getInverseOperator(int type) { switch (type) { case Token.GT: return Token.LT; case Token.LT: return Token.GT; case Token.GE: return Token.LE; case Token.LE: return Token.GE; } return Token.ERROR; }
Example 16
Source File: Cardumen_00200_s.java From coming with MIT License | 5 votes |
/** * Returns the inverse of an operator if it is invertible. * ex. '>' ==> '<' */ static int getInverseOperator(int type) { switch (type) { case Token.GT: return Token.LT; case Token.LT: return Token.GT; case Token.GE: return Token.LE; case Token.LE: return Token.GE; } return Token.ERROR; }
Example 17
Source File: Reader.java From astor with GNU General Public License v2.0 | 4 votes |
/** * Returns assign operator associated with a specified name. */ private static int getNodeTypeForAssignOp(String name) { Operator op = get(name); if (op == null) { return Token.ERROR; } int type; switch (op) { case ASSIGN: type = Token.ASSIGN; break; case ASSIGN_BITOR: type = Token.ASSIGN_BITOR; break; case ASSIGN_BITXOR: type = Token.ASSIGN_BITXOR; break; case ASSIGN_BITAND: type = Token.ASSIGN_BITAND; break; case ASSIGN_LSH: type = Token.ASSIGN_LSH; break; case ASSIGN_RSH: type = Token.ASSIGN_RSH; break; case ASSIGN_URSH: type = Token.ASSIGN_URSH; break; case ASSIGN_ADD: type = Token.ASSIGN_ADD; break; case ASSIGN_SUB: type = Token.ASSIGN_SUB; break; case ASSIGN_MUL: type = Token.ASSIGN_MUL; break; case ASSIGN_DIV: type = Token.ASSIGN_DIV; break; case ASSIGN_MOD: type = Token.ASSIGN_MOD; break; default: throw new IllegalArgumentException("" + "Invalid type of assign expression."); } return type; }
Example 18
Source File: ProcessTweaks.java From astor with GNU General Public License v2.0 | 4 votes |
TweakFunction(String name) { this(name, null, Token.ERROR, Token.ERROR, null); }
Example 19
Source File: ProcessTweaks.java From astor with GNU General Public License v2.0 | 4 votes |
TweakFunction(String name, String expectedTypeName, int validNodeTypeA) { this(name, expectedTypeName, validNodeTypeA, Token.ERROR, null); }
Example 20
Source File: ProcessTweaks.java From astor with GNU General Public License v2.0 | 4 votes |
TweakFunction(String name, TweakFunction registerFunction) { this(name, null, Token.ERROR, Token.ERROR, registerFunction); }