Package com.objfac.prebop

Examples of com.objfac.prebop.Expression


     * @param line the line containing the expression
     * @return <code>true</code> if the expression evaluates <code>true</code>, else
     *         <code>false</code>
     */
    private boolean evaluate(String line) {
      Expression exp;
      try {
        exp = new Expression(line.getBytes(), line.indexOf("if") + 2, vars);
      }
      catch (PreprocessorError e) {
        throw new RuntimeException("Failed to contruct expression: " + line, e);
      }
      try {
        return exp.eval();
      }
      catch (PreprocessorError e) {
        throw new RuntimeException("Failed to process expression: " + line, e);
      }
    }
View Full Code Here

TOP

Related Classes of com.objfac.prebop.Expression

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.