Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.codehaus.aspectwerkz.expression.ast
Class ExpressionParser

    java.lang.Object
      org.codehaus.aspectwerkz.expression.ast.ExpressionParser

All Implemented Interfaces:
  ExpressionParserConstants, ExpressionParserTreeConstants

    public class ExpressionParser

extends Object
implements ExpressionParserTreeConstants, ExpressionParserConstants

Usage:

         ExpressionParser parser = new ExpressionParser(System.in); // can be only one
         ASTRoot root = parser.parse("call(@RequiresNew public * foo.Bar.*(String, ..) AND withincode(* foo.Baz.within(..)");
         Expression expression = new Expression(root);
         ...

TODO: the grammar is still fragile

Author:
  Jonas BonŽr, Alexandre Vasseur, Alex Popescu

Field Summary
`static Token` | `jj_nt`
`protected static org.codehaus.aspectwerkz.expression.ast.JJTExpressionParserState` | `jjtree`
`static boolean` | `lookingAhead`
`static Token` | `token`
`static ExpressionParserTokenManager` | `token_source`

Fields inherited from interface org.codehaus.aspectwerkz.expression.ast.ExpressionParserTreeConstants
`JJTAND, JJTARGPARAMETER, JJTARGS, JJTATTRIBUTE, JJTCALL, JJTCFLOW, JJTCFLOWBELOW, JJTCLASSPATTERN, JJTCONSTRUCTORPATTERN, JJTEXECUTION, JJTEXPRESSION, JJTFIELDPATTERN, JJTGET, JJTHANDLER, JJTHASFIELD, JJTHASMETHOD, JJTMETHODPATTERN, JJTMODIFIER, jjtNodeName, JJTNOT, JJTOR, JJTPARAMETER, JJTPOINTCUTREFERENCE, JJTROOT, JJTSET, JJTSTATICINITIALIZATION, JJTTARGET, JJTTHIS, JJTVOID, JJTWITHIN, JJTWITHINCODE`

Fields inherited from interface org.codehaus.aspectwerkz.expression.ast.ExpressionParserConstants
`AND, ARG_ARRAY_PATTERN, ARG_IDENTIFIER, ARG_JAVA_NAME_LETTER, ARG_PATTERN, ARGS, ARGS_END, ARRAY, CALL, CFLOW, CFLOW_BELOW, CLASS, CLASS_ABSTRACT, CLASS_ATTRIBUTE, CLASS_EXACT_IDENTIFIER, CLASS_FINAL, CLASS_IDENTIFIER, CLASS_JAVA_NAME_LETTER, CLASS_NOT, CLASS_PATTERN, CLASS_POINTCUT_END, CLASS_PRIVATE, CLASS_PROTECTED, CLASS_PUBLIC, CLASS_STATIC, COMMA, DEFAULT, DOT, EAGER_WILDCARD, EOF, EXECUTION, FIELD, FIELD_ABSTRACT, FIELD_ANNOTATION, FIELD_ARRAY_CLASS_PATTERN, FIELD_ATTRIBUTE_EXACT_IDENTIFIER, FIELD_CLASS_PATTERN, FIELD_FINAL, FIELD_IDENTIFIER, FIELD_JAVA_NAME_LETTER, FIELD_NOT, FIELD_POINTCUT_END, FIELD_PRIVATE, FIELD_PROTECTED, FIELD_PUBLIC, FIELD_STATIC, FIELD_TRANSIENT, GET, HANDLER, HAS_FIELD, HAS_METHOD, IF, IN_ARGS, METHOD, METHOD_ABSTRACT, METHOD_ANNOTATION, METHOD_ARRAY_CLASS_PATTERN, METHOD_ATTRIBUTE_EXACT_IDENTIFIER, METHOD_CLASS_PATTERN, METHOD_FINAL, METHOD_IDENTIFIER, METHOD_JAVA_NAME_LETTER, METHOD_NATIVE, METHOD_NOT, METHOD_PARAMETER_END, METHOD_PARAMETER_START, METHOD_PRIVATE, METHOD_PROTECTED, METHOD_PUBLIC, METHOD_STATIC, METHOD_SYNCHRONIZED, NOT, OR, PARAMETER_ANNOTATION, PARAMETER_ARRAY_CLASS_PATTERN, PARAMETER_CLASS_PATTERN, PARAMETER_IDENTIFIER, PARAMETER_JAVA_NAME_LETTER, PARAMETER_NOT, PARAMETERS, POINTCUT_REFERENCE, POINTCUT_REFERENCE_WITH_ARGS, SET, STATIC_INITIALIZATION, TARGET, THIS, tokenImage, TYPE_STATICINITIALIZATION, WILDCARD, WITHIN, WITHIN_CODE`

Constructor Summary
`ExpressionParser(ExpressionParserTokenManager tm)`
`ExpressionParser(InputStream stream)`
`ExpressionParser(Reader stream)`

Method Summary
`static void` | `AndExpression()` AndExpression.
`static void` | `ArgParameter()` ArgParameter.
`static void` | `Args()` Args.
`static void` | `ArgsParameters()` ArgsParameters.
`static void` | `Call()` Call.
`static void` | `Cflow()` Cflow.
`static void` | `CflowBelow()` CflowBelow.
`static void` | `ClassAttribute()` Class annotation.
`static void` | `ClassModifier()` Class modifier.
`static void` | `ClassPattern()` Class pattern.
`static void` | `ConstructorModifier()` Constructor modifier.
`static void` | `ConstructorPattern()` Constructor pattern.
`static void` | `disable_tracing()`
`static void` | `enable_tracing()`
`static void` | `Execution()` Execution.
`static void` | `Expression()` Expression.
`static void` | `FieldAttribute()` Field annotation.
`static void` | `FieldModifier()` Field modifier.
`static void` | `FieldPattern()` Field pattern.
`static ParseException` | `generateParseException()`
`static void` | `Get()` Get.
`static Token` | `getNextToken()`
`static Token` | `getToken(int index)`
`static void` | `Handler()` Handler.
`static void` | `HasField()` HasField.
`static void` | `HasMethod()` HasMethod.
`static void` | `MethodAttribute()` Method annotation.
`static void` | `MethodModifier()` Method modifier.
`static void` | `MethodPattern()` Method pattern.
`static void` | `NotExpression()` NotExpression.
`static void` | `OrExpression()` OrExpression.
`static void` | `Parameter()` Parameter pattern.
`static void` | `Parameters()` Parameters.
`ASTRoot` | `parse(Reader reader)`
`ASTRoot` | `parse(String expression)`
`static void` | `Pointcut()` Pointcut.
`static void` | `PointcutReference()` Pointcut reference.
`void` | `ReInit(ExpressionParserTokenManager tm)`
`static void` | `ReInit(InputStream stream)`
`static void` | `ReInit(Reader stream)`
`static ASTRoot` | `Root()` Entry point.
`static void` | `Set()` Set.
`static void` | `StaticInitialization()` StaticInitialization.
`static void` | `StaticInitializationPattern()`
`static void` | `StaticInitializationPatternModifier()` Method modifier.
`static void` | `Target()` Target
`static void` | `This()` This
`static void` | `UnaryExpression()` UnaryExpression.
`static void` | `Within()` Within.
`static void` | `WithinCode()` WithinCode.
`static void` | `WithinStaticInitialization()`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### jjtree

    protected static org.codehaus.aspectwerkz.expression.ast.JJTExpressionParserState jjtree

### token_source

    public static ExpressionParserTokenManager token_source

### token

    public static Token token

### jj_nt

    public static Token jj_nt

### lookingAhead

    public static boolean lookingAhead

Constructor Detail

### ExpressionParser

    public ExpressionParser(InputStream stream)

### ExpressionParser

    public ExpressionParser(Reader stream)

### ExpressionParser

    public ExpressionParser(ExpressionParserTokenManager tm)

Method Detail

### parse

    public ASTRoot parse(String expression)
                  throws ParseException

  Throws:
    `ParseException`

### parse

    public ASTRoot parse(Reader reader)
                  throws ParseException

  Throws:
    `ParseException`

### Root

    public static final ASTRoot Root()
                              throws ParseException

  Entry point.

  Throws:
    `ParseException`

### Expression

    public static final void Expression()
                                 throws ParseException

  Expression.

  Throws:
    `ParseException`

### AndExpression

    public static final void AndExpression()
                                    throws ParseException

  AndExpression.

  Throws:
    `ParseException`

### OrExpression

    public static final void OrExpression()
                                   throws ParseException

  OrExpression.

  Throws:
    `ParseException`

### UnaryExpression

    public static final void UnaryExpression()
                                      throws ParseException

  UnaryExpression.

  Throws:
    `ParseException`

### NotExpression

    public static final void NotExpression()
                                    throws ParseException

  NotExpression.

  Throws:
    `ParseException`

### Pointcut

    public static final void Pointcut()
                               throws ParseException

  Pointcut.

  Throws:
    `ParseException`

### PointcutReference

    public static final void PointcutReference()
                                        throws ParseException

  Pointcut reference.

  Throws:
    `ParseException`

### Execution

    public static final void Execution()
                                throws ParseException

  Execution.

  Throws:
    `ParseException`

### Call

    public static final void Call()
                           throws ParseException

  Call.

  Throws:
    `ParseException`

### Set

    public static final void Set()
                          throws ParseException

  Set.

  Throws:
    `ParseException`

### Get

    public static final void Get()
                          throws ParseException

  Get.

  Throws:
    `ParseException`

### Handler

    public static final void Handler()
                              throws ParseException

  Handler.

  Throws:
    `ParseException`

### Within

    public static final void Within()
                             throws ParseException

  Within.

  Throws:
    `ParseException`

### WithinCode

    public static final void WithinCode()
                                 throws ParseException

  WithinCode.

  Throws:
    `ParseException`

### WithinStaticInitialization

    public static final void WithinStaticInitialization()
                                                 throws ParseException

  Throws:
    `ParseException`

### StaticInitializationPattern

    public static final void StaticInitializationPattern()
                                                  throws ParseException

  Throws:
    `ParseException`

### StaticInitialization

    public static final void StaticInitialization()
                                           throws ParseException

  StaticInitialization.

  Throws:
    `ParseException`

### Cflow

    public static final void Cflow()
                            throws ParseException

  Cflow.

  Throws:
    `ParseException`

### CflowBelow

    public static final void CflowBelow()
                                 throws ParseException

  CflowBelow.

  Throws:
    `ParseException`

### Args

    public static final void Args()
                           throws ParseException

  Args.

  Throws:
    `ParseException`

### HasMethod

    public static final void HasMethod()
                                throws ParseException

  HasMethod.

  Throws:
    `ParseException`

### HasField

    public static final void HasField()
                               throws ParseException

  HasField.

  Throws:
    `ParseException`

### Target

    public static final void Target()
                             throws ParseException

  Target

  Throws:
    `ParseException`

### This

    public static final void This()
                           throws ParseException

  This

  Throws:
    `ParseException`

### ClassPattern

    public static final void ClassPattern()
                                   throws ParseException

  Class pattern.

  Throws:
    `ParseException`

### MethodPattern

    public static final void MethodPattern()
                                    throws ParseException

  Method pattern.

  Throws:
    `ParseException`

### ConstructorPattern

    public static final void ConstructorPattern()
                                         throws ParseException

  Constructor pattern.

  Throws:
    `ParseException`

### FieldPattern

    public static final void FieldPattern()
                                   throws ParseException

  Field pattern.

  Throws:
    `ParseException`

### Parameters

    public static final void Parameters()
                                 throws ParseException

  Parameters.

  Throws:
    `ParseException`

### Parameter

    public static final void Parameter()
                                throws ParseException

  Parameter pattern.

  Throws:
    `ParseException`

### ArgsParameters

    public static final void ArgsParameters()
                                     throws ParseException

  ArgsParameters.

  Throws:
    `ParseException`

### ArgParameter

    public static final void ArgParameter()
                                   throws ParseException

  ArgParameter.

  Throws:
    `ParseException`

### ClassAttribute

    public static final void ClassAttribute()
                                     throws ParseException

  Class annotation.

  Throws:
    `ParseException`

### MethodAttribute

    public static final void MethodAttribute()
                                      throws ParseException

  Method annotation.

  Throws:
    `ParseException`

### FieldAttribute

    public static final void FieldAttribute()
                                     throws ParseException

  Field annotation.

  Throws:
    `ParseException`

### ClassModifier

    public static final void ClassModifier()
                                    throws ParseException

  Class modifier.

  Throws:
    `ParseException`

### StaticInitializationPatternModifier

    public static final void StaticInitializationPatternModifier()
                                                          throws ParseException

  Method modifier.

  Throws:
    `ParseException`

### MethodModifier

    public static final void MethodModifier()
                                     throws ParseException

  Method modifier.

  Throws:
    `ParseException`

### ConstructorModifier

    public static final void ConstructorModifier()
                                          throws ParseException

  Constructor modifier.

  Throws:
    `ParseException`

### FieldModifier

    public static final void FieldModifier()
                                    throws ParseException

  Field modifier.

  Throws:
    `ParseException`

### ReInit

    public static void ReInit(InputStream stream)

### ReInit

    public static void ReInit(Reader stream)

### ReInit

    public void ReInit(ExpressionParserTokenManager tm)

### getNextToken

    public static final Token getNextToken()

### getToken

    public static final Token getToken(int index)

### generateParseException

    public static ParseException generateParseException()

### enable_tracing

    public static final void enable_tracing()

### disable_tracing

    public static final void disable_tracing()

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2002-2005 Jonas Bonér, Alexandre Vasseur. All Rights Reserved.