src/main/java/ognl/Ognl.java
public static Object parseExpression(String expression)
            throws OgnlException
    {
        try {
            OgnlParser parser = new OgnlParser(new StringReader(expression));
            return parser.topLevelExpression();
        } catch (ParseException e) {
            throw new ExpressionSyntaxException(expression, e);
        } catch (TokenMgrError e) {
            throw new ExpressionSyntaxException(expression, e);
        }
    }
public static Object parseExpression(String expression)
            throws OgnlException
    {
        try {
            OgnlParser parser = new OgnlParser(new StringReader(expression));
            return parser.topLevelExpression();
        } catch (ParseException e) {
            throw new ExpressionSyntaxException(expression, e);
        } catch (TokenMgrError e) {
            throw new ExpressionSyntaxException(expression, e);
        }
    }
public static Object parseExpression ( String expression ) throws OgnlException { try { OgnlParser parser = new OgnlParser ( new StringReader ( expression ) ) ; return parser . topLevelExpression ( ) ; } catch ( ParseException e ) { throw new ExpressionSyntaxException ( expression , e ) ; } catch ( TokenMgrError e ) { throw new ExpressionSyntaxException ( expression , e ) ; } }
Parses the given OGNL expression and returns a tree representation of the expression that can
be used by <CODE>Ognl</CODE> static methods.

@param expression
the OGNL expression to be parsed
@return a tree representation of the expression
@throws ExpressionSyntaxException
if the expression is malformed
@throws OgnlException
if there is a pathological environmental problem
Parses the given OGNL expression and returns a tree representation of the expression that can be used by <CODE > Ognl< / CODE > static methods .