title: JEXL - How to get all warning message of unknown variables?
body: <p>How to get all warning message of unknown variables?</p>
  
  <p>I have a expression which I would like to evaluate and know all the missing variables.</p>
  
  <p>Example:</p>
  
  <pre><code>jexl.setStrict(false);
  Expression e = (Expression) jexl.createExpression("(pqr||abc)&amp;&amp;xyx&amp;&amp;!(rsw||ruy)&amp;&amp;!sss");
  
  JexlContext context = new MapContext();
   context.set("rsw",false);  
   context.set("xyx",true);   
   Object obj=e.evaluate(context);
   System.out.println(obj);
  </code></pre>
  
  <p>Output: </p>
  
  <pre><code>Aug 11, 2017 10:58:24 AM org.apache.commons.jexl2.Interpreter unknownVariable
  WARNING: com.AdhocPrograms.JexlExample.main@40![1,4]: '(pqr || abc) &amp;&amp; xyx &amp;&amp; !(rsw || ruy) &amp;&amp; !sss;' undefined variable pqr
  false
  Aug 11, 2017 10:58:24 AM org.apache.commons.jexl2.Interpreter unknownVariable
  WARNING: com.AdhocPrograms.JexlExample.main@40![8,11]: '(pqr || abc) &amp;&amp; xyx &amp;&amp; !(rsw || ruy) &amp;&amp; !sss;' undefined variable abc
  </code></pre>
  
  <p>I would like to capture both of the undefined variables. If I set jexl.setStrict(true) and add try and catch block, I can capture only one variable.</p>
  
  <pre><code>  catch(JexlException.Variable xjexl)       {
              System.out.println("Exception:" +xjexl.getVariable());          
              xjexl.printStackTrace();
          }
  </code></pre>
  
  <p>I am open to use another technology as well.</p>