Package org.objectweb.joram.shared.selectors

Source Code of org.objectweb.joram.shared.selectors.CUP$Filter$actions

/*
* JORAM: Java(TM) Open Reliable Asynchronous Messaging
* Copyright (C) 2001 - 2009 ScalAgent Distributed Technologies
* Copyright (C) 2004 - Bull SA
* Copyright (C) 1996 - 2000 Dyade
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
* version 2.1 of the License, or any later version.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307
* USA.
*
* Initial developer(s): Frederic Maistre (INRIA)
* Contributor(s): Nicolas Tachker (Bull SA)
*                 ScalAgent Distributed Technologies
*/

//----------------------------------------------------
// The following code was generated by CUP v0.10j
// Fri Jun 18 16:25:44 CEST 2004
//----------------------------------------------------

package org.objectweb.joram.shared.selectors;

import java.util.StringTokenizer;
import java.util.regex.Pattern;

import java_cup.runtime.Scanner;
import java_cup.runtime.Symbol;

import org.objectweb.joram.shared.messages.Message;

/** CUP v0.10j generated parser.
  * @version Fri Jun 18 16:25:44 CEST 2004
  */
public class Filter extends java_cup.runtime.lr_parser {

  /** Default constructor. */
  public Filter() {super();}

  /** Constructor which sets the default scanner. */
  public Filter(java_cup.runtime.Scanner s) {super(s);}

  /** Production table. */
  protected static final short _production_table[][] =
    unpackFromStrings(new String[] {
    "\000\053\000\002\003\005\000\002\002\004\000\002\003" +
    "\005\000\002\003\004\000\002\003\003\000\002\004\005" +
    "\000\002\004\005\000\002\004\005\000\002\004\005\000" +
    "\002\004\005\000\002\004\005\000\002\004\005\000\002" +
    "\004\007\000\002\004\007\000\002\004\007\000\002\004" +
    "\010\000\002\004\005\000\002\004\006\000\002\004\007" +
    "\000\002\004\010\000\002\004\005\000\002\004\006\000" +
    "\002\004\003\000\002\005\005\000\002\005\003\000\002" +
    "\006\005\000\002\006\005\000\002\006\005\000\002\006" +
    "\005\000\002\006\004\000\002\006\004\000\002\006\004" +
    "\000\002\006\003\000\002\007\005\000\002\007\003\000" +
    "\002\007\003\000\002\007\003\000\002\007\003\000\002" +
    "\007\003\000\002\007\003\000\002\007\003\000\002\007" +
    "\003\000\002\007\003" });

  /** Access to production table. */
  public short[][] production_table() {return _production_table;}

  /** Parse-action table. */
  protected static final short[][] _action_table =
    unpackFromStrings(new String[] {
    "\000\126\000\034\004\010\005\004\011\021\024\017\034" +
    "\013\035\022\036\006\037\011\040\005\041\024\042\007" +
    "\043\014\044\012\001\002\000\032\004\010\005\004\011" +
    "\046\034\013\035\022\036\006\037\011\040\005\041\024" +
    "\042\007\043\044\044\012\001\002\000\042\002\uffda\004" +
    "\uffda\005\uffda\007\uffda\010\uffda\012\uffda\014\uffda\015\uffda" +
    "\016\uffda\017\uffda\020\uffda\021\uffda\022\uffda\023\uffda\026" +
    "\uffda\027\uffda\001\002\000\042\002\uffdc\004\uffdc\005\uffdc" +
    "\007\uffdc\010\uffdc\012\uffdc\014\uffdc\015\uffdc\016\uffdc\017" +
    "\uffdc\020\uffdc\021\uffdc\022\uffdc\023\uffdc\026\uffdc\027\uffdc" +
    "\001\002\000\042\002\uffd7\004\uffd7\005\uffd7\007\uffd7\010" +
    "\uffd7\012\uffd7\014\uffd7\015\uffd7\016\uffd7\017\uffd7\020\uffd7" +
    "\021\uffd7\022\uffd7\023\uffd7\026\uffd7\027\uffd7\001\002\000" +
    "\032\004\010\005\004\011\046\034\013\035\022\036\006" +
    "\037\011\040\005\041\024\042\007\043\044\044\012\001" +
    "\002\000\066\002\uffdb\004\010\005\004\007\uffdb\010\uffdb" +
    "\011\046\012\uffdb\014\uffdb\015\uffdb\016\uffdb\017\uffdb\020" +
    "\uffdb\021\uffdb\022\uffdb\023\uffdb\026\uffdb\027\uffdb\034\013" +
    "\035\022\036\006\037\011\040\005\041\024\042\007\043" +
    "\044\044\012\001\002\000\042\002\uffd8\004\uffd8\005\uffd8" +
    "\007\uffd8\010\uffd8\012\uffd8\014\uffd8\015\uffd8\016\uffd8\017" +
    "\uffd8\020\uffd8\021\uffd8\022\uffd8\023\uffd8\026\uffd8\027\uffd8" +
    "\001\002\000\042\002\uffde\004\uffde\005\uffde\007\uffde\010" +
    "\uffde\012\uffde\014\uffde\015\uffde\016\uffde\017\uffde\020\uffde" +
    "\021\uffde\022\uffde\023\uffde\026\uffde\027\uffde\001\002\000" +
    "\052\002\uffdf\004\uffdf\005\uffdf\007\uffdf\010\uffdf\012\uffdf" +
    "\014\uffdf\015\uffdf\016\uffdf\017\uffdf\020\uffdf\021\uffdf\022" +
    "\uffdf\023\uffdf\024\100\025\076\026\uffdf\027\uffdf\030\077" +
    "\032\101\001\002\000\042\002\uffe1\004\uffe1\005\uffe1\007" +
    "\uffe1\010\uffe1\012\uffe1\014\uffe1\015\uffe1\016\uffe1\017\uffe1" +
    "\020\uffe1\021\uffe1\022\uffe1\023\uffe1\026\uffe1\027\uffe1\001" +
    "\002\000\010\002\075\022\070\023\071\001\002\000\034" +
    "\004\010\005\004\011\021\024\017\034\013\035\022\036" +
    "\006\037\011\040\005\041\024\042\007\043\014\044\012" +
    "\001\002\000\042\002\uffeb\004\033\005\027\007\042\010" +
    "\030\012\uffeb\014\040\015\031\016\043\017\035\020\034" +
    "\021\032\022\uffeb\023\uffeb\026\036\027\037\001\002\000" +
    "\034\004\010\005\004\011\021\024\017\034\013\035\022" +
    "\036\006\037\011\040\005\041\024\042\007\043\014\044" +
    "\012\001\002\000\042\002\uffdd\004\uffdd\005\uffdd\007\uffdd" +
    "\010\uffdd\012\uffdd\014\uffdd\015\uffdd\016\uffdd\017\uffdd\020" +
    "\uffdd\021\uffdd\022\uffdd\023\uffdd\026\uffdd\027\uffdd\001\002" +
    "\000\012\002\ufffd\012\ufffd\022\ufffd\023\ufffd\001\002\000" +
    "\042\002\uffd9\004\uffd9\005\uffd9\007\uffd9\010\uffd9\012\uffd9" +
    "\014\uffd9\015\uffd9\016\uffd9\017\uffd9\020\uffd9\021\uffd9\022" +
    "\uffd9\023\uffd9\026\uffd9\027\uffd9\001\002\000\010\012\067" +
    "\022\070\023\071\001\002\000\040\004\033\005\027\007" +
    "\042\010\030\012\041\014\040\015\031\016\043\017\035" +
    "\020\034\021\032\022\uffeb\023\uffeb\026\036\027\037\001" +
    "\002\000\032\004\010\005\004\011\046\034\013\035\022" +
    "\036\006\037\011\040\005\041\024\042\007\043\044\044" +
    "\012\001\002\000\032\004\010\005\004\011\046\034\013" +
    "\035\022\036\006\037\011\040\005\041\024\042\007\043" +
    "\044\044\012\001\002\000\032\004\010\005\004\011\046" +
    "\034\013\035\022\036\006\037\011\040\005\041\024\042" +
    "\007\043\044\044\012\001\002\000\032\004\010\005\004" +
    "\011\046\034\013\035\022\036\006\037\011\040\005\041" +
    "\024\042\007\043\044\044\012\001\002\000\032\004\010" +
    "\005\004\011\046\034\013\035\022\036\006\037\011\040" +
    "\005\041\024\042\007\043\044\044\012\001\002\000\032" +
    "\004\010\005\004\011\046\034\013\035\022\036\006\037" +
    "\011\040\005\041\024\042\007\043\044\044\012\001\002" +
    "\000\032\004\010\005\004\011\046\034\013\035\022\036" +
    "\006\037\011\040\005\041\024\042\007\043\044\044\012" +
    "\001\002\000\032\004\010\005\004\011\046\034\013\035" +
    "\022\036\006\037\011\040\005\041\024\042\007\043\044" +
    "\044\012\001\002\000\032\004\010\005\004\011\046\034" +
    "\013\035\022\036\006\037\011\040\005\041\024\042\007" +
    "\043\044\044\012\001\002\000\032\004\010\005\004\011" +
    "\046\034\013\035\022\036\006\037\011\040\005\041\024" +
    "\042\007\043\044\044\012\001\002\000\042\002\uffe0\004" +
    "\uffe0\005\uffe0\007\uffe0\010\uffe0\012\uffe0\014\uffe0\015\uffe0" +
    "\016\uffe0\017\uffe0\020\uffe0\021\uffe0\022\uffe0\023\uffe0\026" +
    "\uffe0\027\uffe0\001\002\000\032\004\010\005\004\011\046" +
    "\034\013\035\022\036\006\037\011\040\005\041\024\042" +
    "\007\043\044\044\012\001\002\000\032\004\010\005\004" +
    "\011\046\034\013\035\022\036\006\037\011\040\005\041" +
    "\024\042\007\043\044\044\012\001\002\000\042\002\uffdf" +
    "\004\uffdf\005\uffdf\007\uffdf\010\uffdf\012\uffdf\014\uffdf\015" +
    "\uffdf\016\uffdf\017\uffdf\020\uffdf\021\uffdf\022\uffdf\023\uffdf" +
    "\026\uffdf\027\uffdf\001\002\000\022\002\ufff9\004\033\005" +
    "\027\007\042\010\030\012\ufff9\022\ufff9\023\ufff9\001\002" +
    "\000\032\004\010\005\004\011\046\034\013\035\022\036" +
    "\006\037\011\040\005\041\024\042\007\043\044\044\012" +
    "\001\002\000\014\004\033\005\027\007\042\010\030\012" +
    "\041\001\002\000\042\002\uffe6\004\uffe6\005\uffe6\007\uffe6" +
    "\010\uffe6\012\uffe6\014\uffe6\015\uffe6\016\uffe6\017\uffe6\020" +
    "\uffe6\021\uffe6\022\uffe6\023\uffe6\026\uffe6\027\uffe6\001\002" +
    "\000\022\002\ufffb\004\033\005\027\007\042\010\030\012" +
    "\ufffb\022\ufffb\023\ufffb\001\002\000\014\004\033\005\027" +
    "\007\042\010\030\022\053\001\002\000\032\004\010\005" +
    "\004\011\046\034\013\035\022\036\006\037\011\040\005" +
    "\041\024\042\007\043\044\044\012\001\002\000\022\002" +
    "\ufff4\004\033\005\027\007\042\010\030\012\ufff4\022\ufff4" +
    "\023\ufff4\001\002\000\014\004\033\005\027\007\042\010" +
    "\030\022\056\001\002\000\032\004\010\005\004\011\046" +
    "\034\013\035\022\036\006\037\011\040\005\041\024\042" +
    "\007\043\044\044\012\001\002\000\022\002\ufff5\004\033" +
    "\005\027\007\042\010\030\012\ufff5\022\ufff5\023\ufff5\001" +
    "\002\000\022\002\ufff8\004\033\005\027\007\042\010\030" +
    "\012\ufff8\022\ufff8\023\ufff8\001\002\000\022\002\ufff7\004" +
    "\033\005\027\007\042\010\030\012\ufff7\022\ufff7\023\ufff7" +
    "\001\002\000\042\002\uffe8\004\uffe8\005\uffe8\007\042\010" +
    "\030\012\uffe8\014\uffe8\015\uffe8\016\uffe8\017\uffe8\020\uffe8" +
    "\021\uffe8\022\uffe8\023\uffe8\026\uffe8\027\uffe8\001\002\000" +
    "\022\002\ufff6\004\033\005\027\007\042\010\030\012\ufff6" +
    "\022\ufff6\023\ufff6\001\002\000\022\002\ufffa\004\033\005" +
    "\027\007\042\010\030\012\ufffa\022\ufffa\023\ufffa\001\002" +
    "\000\042\002\uffe5\004\uffe5\005\uffe5\007\uffe5\010\uffe5\012" +
    "\uffe5\014\uffe5\015\uffe5\016\uffe5\017\uffe5\020\uffe5\021\uffe5" +
    "\022\uffe5\023\uffe5\026\uffe5\027\uffe5\001\002\000\042\002" +
    "\uffe7\004\uffe7\005\uffe7\007\042\010\030\012\uffe7\014\uffe7" +
    "\015\uffe7\016\uffe7\017\uffe7\020\uffe7\021\uffe7\022\uffe7\023" +
    "\uffe7\026\uffe7\027\uffe7\001\002\000\012\002\ufffc\012\ufffc" +
    "\022\ufffc\023\ufffc\001\002\000\034\004\010\005\004\011" +
    "\021\024\017\034\013\035\022\036\006\037\011\040\005" +
    "\041\024\042\007\043\014\044\012\001\002\000\034\004" +
    "\010\005\004\011\021\024\017\034\013\035\022\036\006" +
    "\037\011\040\005\041\024\042\007\043\014\044\012\001" +
    "\002\000\012\002\001\012\001\022\070\023\001\001\002" +
    "\000\012\002\uffff\012\uffff\022\uffff\023\uffff\001\002\000" +
    "\012\002\ufffe\012\ufffe\022\ufffe\023\ufffe\001\002\000\004" +
    "\002\000\001\002\000\004\044\123\001\002\000\004\011" +
    "\120\001\002\000\006\025\105\030\106\001\002\000\006" +
    "\024\102\033\103\001\002\000\004\033\104\001\002\000" +
    "\012\002\uffed\012\uffed\022\uffed\023\uffed\001\002\000\012" +
    "\002\uffec\012\uffec\022\uffec\023\uffec\001\002\000\004\044" +
    "\115\001\002\000\004\011\107\001\002\000\004\044\111" +
    "\001\002\000\006\012\113\013\112\001\002\000\006\012" +
    "\uffe9\013\uffe9\001\002\000\004\044\114\001\002\000\012" +
    "\002\ufff2\012\ufff2\022\ufff2\023\ufff2\001\002\000\006\012" +
    "\uffea\013\uffea\001\002\000\014\002\ufff0\012\ufff0\022\ufff0" +
    "\023\ufff0\031\116\001\002\000\004\044\117\001\002\000" +
    "\012\002\uffee\012\uffee\022\uffee\023\uffee\001\002\000\004" +
    "\044\111\001\002\000\006\012\122\013\112\001\002\000" +
    "\012\002\ufff3\012\ufff3\022\ufff3\023\ufff3\001\002\000\014" +
    "\002\ufff1\012\ufff1\022\ufff1\023\ufff1\031\124\001\002\000" +
    "\004\044\125\001\002\000\012\002\uffef\012\uffef\022\uffef" +
    "\023\uffef\001\002\000\042\002\uffe2\004\033\005\027\007" +
    "\042\010\030\012\uffe2\014\uffe2\015\uffe2\016\uffe2\017\uffe2" +
    "\020\uffe2\021\uffe2\022\uffe2\023\uffe2\026\uffe2\027\uffe2\001" +
    "\002\000\042\002\uffe4\004\uffe4\005\uffe4\007\042\010\030" +
    "\012\uffe4\014\uffe4\015\uffe4\016\uffe4\017\uffe4\020\uffe4\021" +
    "\uffe4\022\uffe4\023\uffe4\026\uffe4\027\uffe4\001\002\000\042" +
    "\002\uffe3\004\uffe3\005\uffe3\007\uffe3\010\uffe3\012\uffe3\014" +
    "\uffe3\015\uffe3\016\uffe3\017\uffe3\020\uffe3\021\uffe3\022\uffe3" +
    "\023\uffe3\026\uffe3\027\uffe3\001\002" });

  /** Access to parse-action table. */
  public short[][] action_table() {return _action_table;}

  /** <code>reduce_goto</code> table. */
  protected static final short[][] _reduce_table =
    unpackFromStrings(new String[] {
    "\000\126\000\012\003\015\004\022\006\017\007\014\001" +
    "\001\000\006\006\127\007\014\001\001\000\002\001\001" +
    "\000\002\001\001\000\002\001\001\000\006\006\126\007" +
    "\014\001\001\000\006\006\125\007\014\001\001\000\002" +
    "\001\001\000\002\001\001\000\002\001\001\000\002\001" +
    "\001\000\002\001\001\000\012\003\073\004\022\006\017" +
    "\007\014\001\001\000\002\001\001\000\012\003\024\004" +
    "\022\006\025\007\014\001\001\000\002\001\001\000\002" +
    "\001\001\000\002\001\001\000\002\001\001\000\002\001" +
    "\001\000\006\006\065\007\014\001\001\000\006\006\064" +
    "\007\014\001\001\000\006\006\063\007\014\001\001\000" +
    "\006\006\062\007\014\001\001\000\006\006\061\007\014" +
    "\001\001\000\006\006\060\007\014\001\001\000\006\006" +
    "\057\007\014\001\001\000\006\006\054\007\014\001\001" +
    "\000\006\006\051\007\014\001\001\000\006\006\050\007" +
    "\014\001\001\000\002\001\001\000\006\006\047\007\014" +
    "\001\001\000\006\006\044\007\014\001\001\000\002\001" +
    "\001\000\002\001\001\000\006\006\046\007\014\001\001" +
    "\000\002\001\001\000\002\001\001\000\002\001\001\000" +
    "\002\001\001\000\006\006\053\007\014\001\001\000\002" +
    "\001\001\000\002\001\001\000\006\006\056\007\014\001" +
    "\001\000\002\001\001\000\002\001\001\000\002\001\001" +
    "\000\002\001\001\000\002\001\001\000\002\001\001\000" +
    "\002\001\001\000\002\001\001\000\002\001\001\000\012" +
    "\003\072\004\022\006\017\007\014\001\001\000\012\003" +
    "\071\004\022\006\017\007\014\001\001\000\002\001\001" +
    "\000\002\001\001\000\002\001\001\000\002\001\001\000" +
    "\002\001\001\000\002\001\001\000\002\001\001\000\002" +
    "\001\001\000\002\001\001\000\002\001\001\000\002\001" +
    "\001\000\002\001\001\000\002\001\001\000\004\005\107" +
    "\001\001\000\002\001\001\000\002\001\001\000\002\001" +
    "\001\000\002\001\001\000\002\001\001\000\002\001\001" +
    "\000\002\001\001\000\002\001\001\000\004\005\120\001" +
    "\001\000\002\001\001\000\002\001\001\000\002\001\001" +
    "\000\002\001\001\000\002\001\001\000\002\001\001\000" +
    "\002\001\001\000\002\001\001" });

  /** Access to <code>reduce_goto</code> table. */
  public short[][] reduce_table() {return _reduce_table;}

  /** Instance of action encapsulation class. */
  protected CUP$Filter$actions action_obj;

  /** Action encapsulation object initializer. */
  protected void init_actions()
    {
      action_obj = new CUP$Filter$actions(this, message, syntaxType);
    }

  /** Invoke a user supplied parse action. */
  public java_cup.runtime.Symbol do_action(
    int                        act_num,
    java_cup.runtime.lr_parser parser,
    java.util.Stack            stack,
    int                        top)
    throws java.lang.Exception
  {
    /* call code in generated class */
    return action_obj.CUP$Filter$do_action(act_num, parser, stack, top);
  }

  /** Indicates start state. */
  public int start_state() {return 0;}
  /** Indicates start production. */
  public int start_production() {return 1;}

  /** <code>EOF</code> Symbol index. */
  public int EOF_sym() {return 0;}

  /** <code>error</code> Symbol index. */
  public int error_sym() {return 1;}



  private Message message;
  private String syntaxType;

  /** Constructor which sets the default scanner. */
  public Filter(Scanner s,
                Message message,
                String syntaxType) {
    super(s);
    this.message = message;
    this.syntaxType = syntaxType;
  }

  /* Change the method report_error so it will display the line and
     column of where the error occurred in the input as well as the
     reason for the error which is passed into the method in the
     String 'message'. */
  public void report_error(String message, Object info) {
    /* Create a StringBuffer called 'm' with the string 'Error' in it. */
    StringBuffer m = new StringBuffer("Error");
    /* Check if the information passed to the method is the same
       type as the type Symbol. */
    if (info instanceof Symbol) {
      /* Declare a Symbol object 's' with the
         information in the object info that is being typecasted
         as a Symbol object. */
      Symbol s = ((Symbol) info);
  
      /* Check if the line number in the input is greater or
         equal to zero. */
      if (s.left >= 0) {               
        /* Add to the end of the StringBuffer error message
           the line number of the error in the input. */
        m.append(" in line "+(s.left+1));  
        /* Check if the column number in the input is greater
           or equal to zero. */
        if (s.right >= 0)                   
          /* Add to the end of the StringBuffer error message
             the column number of the error in the input. */
          m.append(", column "+(s.right+1));
      }
    }
  
    /* Add to the end of the StringBuffer error message created in
       this method the message that was passed into this method. */
    m.append(" : "+message);
  
    /* Print the contents of the StringBuffer 'm', which contains
       an error message, out on a line. */
    //System.err.println(m);
    throw new Error(m.toString());
  }
  
  /* Change the method report_fatal_error so when it reports a fatal
     error it will display the line and column number of where the
     fatal error occurred in the input as well as the reason for the
     fatal error which is passed into the method in the object
     'message' and then exit.*/
  public void report_fatal_error(String message, Object info) {
    report_error(message, info);
    //System.exit(1);
  }

}

/** Cup generated class to encapsulate user supplied action code.*/
class CUP$Filter$actions {

  private Message message;
  private String syntaxType;

  /** Constructor */
  CUP$Filter$actions(Filter parser, Message message, String syntaxType) {
    this.parser = parser;
    this.message = message;
    this.syntaxType = syntaxType;
  }

  private final Filter parser;

  /** Constructor */
  CUP$Filter$actions(Filter parser) {
    this.parser = parser;
  }

  /** Method with the actual generated action code. */
  public final java_cup.runtime.Symbol CUP$Filter$do_action(int CUP$Filter$act_num,
      java_cup.runtime.lr_parser CUP$Filter$parser, java.util.Stack CUP$Filter$stack, int CUP$Filter$top)
      throws java.lang.Exception {
    /* Symbol object for return from actions */
    java_cup.runtime.Symbol CUP$Filter$result;

    /* select the action based on the action number */
    switch (CUP$Filter$act_num) {
    /* . . . . . . . . . . . . . . . . . . . . */
    case 42: // lit_expr ::= BOOLEAN
    {
      Object RESULT = null;
      Boolean bool = (Boolean) ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).value;

      RESULT = bool;

      CUP$Filter$result = new java_cup.runtime.Symbol(5/* lit_expr */,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).left,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).right, RESULT);
    }
      return CUP$Filter$result;

      /* . . . . . . . . . . . . . . . . . . . . */
    case 41: // lit_expr ::= STRING
    {
      Object RESULT = null;
      String st = (String) ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).value;

      RESULT = st.substring(1, st.length() - 1);

      CUP$Filter$result = new java_cup.runtime.Symbol(5/* lit_expr */,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).left,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).right, RESULT);
    }
      return CUP$Filter$result;

      /* . . . . . . . . . . . . . . . . . . . . */
    case 40: // lit_expr ::= SHORT
    {
      Object RESULT = null;
      Short num = (Short) ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).value;

      RESULT = num;

      CUP$Filter$result = new java_cup.runtime.Symbol(5/* lit_expr */,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).left,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).right, RESULT);
    }
      return CUP$Filter$result;

      /* . . . . . . . . . . . . . . . . . . . . */
    case 39: // lit_expr ::= INT
    {
      Object RESULT = null;
      Integer num = (Integer) ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).value;

      RESULT = num;

      CUP$Filter$result = new java_cup.runtime.Symbol(5/* lit_expr */,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).left,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).right, RESULT);
    }
      return CUP$Filter$result;

      /* . . . . . . . . . . . . . . . . . . . . */
    case 38: // lit_expr ::= MIN_LONG
    {
      Object RESULT = null;
      Long num = (Long) ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).value;

      RESULT = num;

      CUP$Filter$result = new java_cup.runtime.Symbol(5/* lit_expr */,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).left,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).right, RESULT);
    }
      return CUP$Filter$result;

      /* . . . . . . . . . . . . . . . . . . . . */
    case 37: // lit_expr ::= LONG
    {
      Object RESULT = null;
      Long num = (Long) ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).value;

      RESULT = num;

      CUP$Filter$result = new java_cup.runtime.Symbol(5/* lit_expr */,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).left,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).right, RESULT);
    }
      return CUP$Filter$result;

      /* . . . . . . . . . . . . . . . . . . . . */
    case 36: // lit_expr ::= FLOAT
    {
      Object RESULT = null;
      Float num = (Float) ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).value;

      RESULT = num;

      CUP$Filter$result = new java_cup.runtime.Symbol(5/* lit_expr */,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).left,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).right, RESULT);
    }
      return CUP$Filter$result;

      /* . . . . . . . . . . . . . . . . . . . . */
    case 35: // lit_expr ::= DOUBLE
    {
      Object RESULT = null;
      Double num = (Double) ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).value;

      RESULT = num;

      CUP$Filter$result = new java_cup.runtime.Symbol(5/* lit_expr */,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).left,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).right, RESULT);
    }
      return CUP$Filter$result;

      /* . . . . . . . . . . . . . . . . . . . . */
    case 34: // lit_expr ::= ID
    {
      Object RESULT = null;
      String id = (String) ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).value;

      RESULT = Interpreter.interpret(id, message, syntaxType);

      CUP$Filter$result = new java_cup.runtime.Symbol(5/* lit_expr */,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).left,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).right, RESULT);
    }
      return CUP$Filter$result;

      /* . . . . . . . . . . . . . . . . . . . . */
    case 33: // lit_expr ::= LPAREN expr RPAREN
    {
      Object RESULT = null;
      Object e = ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 1)).value;

      RESULT = e;

      CUP$Filter$result = new java_cup.runtime.Symbol(5/* lit_expr */,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 2)).left,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).right, RESULT);
    }
      return CUP$Filter$result;

      /* . . . . . . . . . . . . . . . . . . . . */
    case 32: // expr ::= lit_expr
    {
      Object RESULT = null;
      Object lit = ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).value;

      RESULT = lit;

      CUP$Filter$result = new java_cup.runtime.Symbol(4/* expr */,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).left,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).right, RESULT);
    }
      return CUP$Filter$result;

      /* . . . . . . . . . . . . . . . . . . . . */
    case 31: // expr ::= MIN_LONG expr
    {
      Object RESULT = null;
      Object e = ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).value;

      RESULT = e;

      CUP$Filter$result = new java_cup.runtime.Symbol(4/* expr */,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 1)).left,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).right, RESULT);
    }
      return CUP$Filter$result;

      /* . . . . . . . . . . . . . . . . . . . . */
    case 30: // expr ::= MINUS expr
    {
      Object RESULT = null;
      Object e = ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).value;

      if (e instanceof Double)
        RESULT = new Double(-((Double) e).doubleValue());
      else if (e instanceof Float)
        RESULT = new Float(-((Float) e).floatValue());
      else if (e instanceof Long)
        RESULT = new Long(-((Long) e).longValue());
      else if (e instanceof Integer)
        RESULT = new Integer(-((Integer) e).intValue());
      // else if (e instanceof Short)
      //   RESULT = new Short(-((Short) e).shortValue());

      CUP$Filter$result = new java_cup.runtime.Symbol(4/* expr */,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 1)).left,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).right, RESULT);
    }
      return CUP$Filter$result;

      /* . . . . . . . . . . . . . . . . . . . . */
    case 29: // expr ::= PLUS expr
    {
      Object RESULT = null;
      Object e = ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).value;

      if (e instanceof Double)
        RESULT = e;
      else if (e instanceof Float)
        RESULT = e;
      else if (e instanceof Long)
        RESULT = e;
      else if (e instanceof Integer)
        RESULT = e;
      else if (e instanceof Short)
        RESULT = e;

      CUP$Filter$result = new java_cup.runtime.Symbol(4/* expr */,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 1)).left,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).right, RESULT);
    }
      return CUP$Filter$result;

      /* . . . . . . . . . . . . . . . . . . . . */
    case 28: // expr ::= expr DIVIDE expr
    {
      Object RESULT = null;
      Object e1 = ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 2)).value;
      Object e2 = ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).value;

      if (e1 instanceof Number && e2 instanceof Number)
        RESULT = new Double(((Number) e1).doubleValue() / ((Number) e2).doubleValue());

      CUP$Filter$result = new java_cup.runtime.Symbol(4/* expr */,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 2)).left,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).right, RESULT);
    }
      return CUP$Filter$result;

      /* . . . . . . . . . . . . . . . . . . . . */
    case 27: // expr ::= expr TIMES expr
    {
      Object RESULT = null;
      Object e1 = ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 2)).value;
      Object e2 = ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).value;

      if (e1 instanceof Number && e2 instanceof Number)
        RESULT = new Double(((Number) e1).doubleValue() * ((Number) e2).doubleValue());

      CUP$Filter$result = new java_cup.runtime.Symbol(4/* expr */,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 2)).left,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).right, RESULT);
    }
      return CUP$Filter$result;

      /* . . . . . . . . . . . . . . . . . . . . */
    case 26: // expr ::= expr MINUS expr
    {
      Object RESULT = null;
      Object e1 = ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 2)).value;
      Object e2 = ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).value;

      if (e1 instanceof Number && e2 instanceof Number)
        RESULT = new Double(((Number) e1).doubleValue() - ((Number) e2).doubleValue());

      CUP$Filter$result = new java_cup.runtime.Symbol(4/* expr */,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 2)).left,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).right, RESULT);
    }
      return CUP$Filter$result;

      /* . . . . . . . . . . . . . . . . . . . . */
    case 25: // expr ::= expr PLUS expr
    {
      Object RESULT = null;
      Object e1 = ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 2)).value;
      Object e2 = ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).value;

      if (e1 instanceof Number && e2 instanceof Number)
        RESULT = new Double(((Number) e1).doubleValue() + ((Number) e2).doubleValue());

      CUP$Filter$result = new java_cup.runtime.Symbol(4/* expr */,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 2)).left,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).right, RESULT);
    }
      return CUP$Filter$result;

      /* . . . . . . . . . . . . . . . . . . . . */
    case 24: // strings ::= STRING
    {
      String RESULT = null;
      String st = (String) ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).value;

      RESULT = st.substring(1, st.length() - 1);

      CUP$Filter$result = new java_cup.runtime.Symbol(3/* strings */,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).left,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).right, RESULT);
    }
      return CUP$Filter$result;

      /* . . . . . . . . . . . . . . . . . . . . */
    case 23: // strings ::= strings COMMA STRING
    {
      String RESULT = null;
      String sts = (String) ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 2)).value;
      String st = (String) ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).value;

      RESULT = sts + "\b" + st.substring(1, st.length() - 1);
      CUP$Filter$result = new java_cup.runtime.Symbol(3/* strings */,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 2)).left,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).right, RESULT);
    }
      return CUP$Filter$result;

      /* . . . . . . . . . . . . . . . . . . . . */
    case 22: // comp_expr ::= expr
    {
      Boolean RESULT = null;
      Object e = ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).value;

      if (e instanceof Boolean)
        RESULT = (Boolean) e;

      CUP$Filter$result = new java_cup.runtime.Symbol(2/* comp_expr */,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).left,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).right, RESULT);
    }
      return CUP$Filter$result;

      /* . . . . . . . . . . . . . . . . . . . . */
    case 21: // comp_expr ::= ID IS NOT NULL
    {
      Boolean RESULT = null;
      String id = (String) ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 3)).value;

      RESULT = new Boolean(Interpreter.interpret(id, message, syntaxType) != null);

      CUP$Filter$result = new java_cup.runtime.Symbol(2/* comp_expr */,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 3)).left,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).right, RESULT);
    }
      return CUP$Filter$result;

      /* . . . . . . . . . . . . . . . . . . . . */
    case 20: // comp_expr ::= ID IS NULL
    {
      Boolean RESULT = null;
      String id = (String) ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 2)).value;

      RESULT = new Boolean(Interpreter.interpret(id, message, syntaxType) == null);

      CUP$Filter$result = new java_cup.runtime.Symbol(2/* comp_expr */,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 2)).left,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).right, RESULT);
    }
      return CUP$Filter$result;

      /* . . . . . . . . . . . . . . . . . . . . */
    case 19: // comp_expr ::= ID NOT LIKE STRING ESCAPE STRING
    {
      Boolean RESULT = null;
      String id = (String) ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 5)).value;
      String st1 = (String) ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 2)).value;
      String st2 = (String) ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).value;

      if (Interpreter.interpret(id, message, syntaxType) == null)
        RESULT = null;

      else if (Interpreter.interpret(id, message, syntaxType) instanceof String) {
        StringBuffer stBuff = new StringBuffer(st1.substring(1, st1.length() - 1));
        StringBuffer stBuffRes = new StringBuffer();
        stBuffRes.append('^');
        char esc = st2.charAt(1);
        for (int i = 0; i < stBuff.length(); i++) {
          if (stBuff.charAt(i) == esc) {
            i++;
            stBuffRes.append(stBuff.charAt(i));
          } else if (stBuff.charAt(i) == '_')
            stBuffRes.append('.');
          else if (stBuff.charAt(i) == '%') {
            stBuffRes.append('.');
            stBuffRes.append('*');
            i++;
          } else {
            stBuffRes.append(stBuff.charAt(i));
          }
        }
        stBuffRes.append('$');
        st1 = stBuffRes.toString();
        RESULT = new Boolean(!Pattern.matches(st1, (String) Interpreter.interpret(id, message, syntaxType)));
      }

      // Comparison of non like values returns FALSE.
      else
        RESULT = Boolean.FALSE;

      CUP$Filter$result = new java_cup.runtime.Symbol(2/* comp_expr */,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 5)).left,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).right, RESULT);
    }
      return CUP$Filter$result;

      /* . . . . . . . . . . . . . . . . . . . . */
    case 18: // comp_expr ::= ID LIKE STRING ESCAPE STRING
    {
      Boolean RESULT = null;
      String id = (String) ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 4)).value;
      String st1 = (String) ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 2)).value;
      String st2 = (String) ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).value;

      if (Interpreter.interpret(id, message, syntaxType) == null)
        RESULT = null;

      else if (Interpreter.interpret(id, message, syntaxType) instanceof String) {
        StringBuffer stBuff = new StringBuffer(st1.substring(1, st1.length() - 1));
        StringBuffer stBuffRes = new StringBuffer();
        stBuffRes.append('^');
        char esc = st2.charAt(1);
        for (int i = 0; i < stBuff.length(); i++) {
          if (stBuff.charAt(i) == esc) {
            i++;
            stBuffRes.append(stBuff.charAt(i));
          } else if (stBuff.charAt(i) == '_')
            stBuffRes.append('.');
          else if (stBuff.charAt(i) == '%') {
            stBuffRes.append('.');
            stBuffRes.append('*');
            i++;
          } else {
            stBuffRes.append(stBuff.charAt(i));
          }
        }
        stBuffRes.append('$');
        st1 = stBuffRes.toString();
        RESULT = new Boolean(Pattern.matches(st1, (String) Interpreter.interpret(id, message, syntaxType)));
      }

      // Comparison of non like values returns FALSE.
      else
        RESULT = Boolean.FALSE;

      CUP$Filter$result = new java_cup.runtime.Symbol(2/* comp_expr */,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 4)).left,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).right, RESULT);
    }
      return CUP$Filter$result;

      /* . . . . . . . . . . . . . . . . . . . . */
    case 17: // comp_expr ::= ID NOT LIKE STRING
    {
      Boolean RESULT = null;
      String id = (String) ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 3)).value;
      String st = (String) ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).value;

      if (Interpreter.interpret(id, message, syntaxType) == null)
        RESULT = null;

      else if (Interpreter.interpret(id, message, syntaxType) instanceof String) {
        StringBuffer stBuff = new StringBuffer(st.substring(1, st.length() - 1));
        stBuff.insert(0, '^');

        for (int i = 0; i < stBuff.length(); i++) {
          if (stBuff.charAt(i) == '_')
            stBuff.setCharAt(i, '.');
          else if (stBuff.charAt(i) == '%') {
            stBuff.setCharAt(i, '.');
            stBuff.insert(i + 1, '*');
            i++;
          }
        }
        stBuff.append('$');

        st = stBuff.toString();
        RESULT = new Boolean(!Pattern.matches(st, (String) Interpreter.interpret(id, message, syntaxType)));
      }
      // Comparison of non like values returns FALSE.
      else
        RESULT = Boolean.FALSE;

      CUP$Filter$result = new java_cup.runtime.Symbol(2/* comp_expr */,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 3)).left,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).right, RESULT);
    }
      return CUP$Filter$result;

      /* . . . . . . . . . . . . . . . . . . . . */
    case 16: // comp_expr ::= ID LIKE STRING
    {
      Boolean RESULT = null;
      String id = (String) ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 2)).value;
      String st = (String) ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).value;

      if (Interpreter.interpret(id, message, syntaxType) == null)
        RESULT = null;

      if (Interpreter.interpret(id, message, syntaxType) instanceof String) {
        StringBuffer stBuff = new StringBuffer(st.substring(1, st.length() - 1));
        stBuff.insert(0, '^');

        for (int i = 0; i < stBuff.length(); i++) {
          if (stBuff.charAt(i) == '_')
            stBuff.setCharAt(i, '.');
          else if (stBuff.charAt(i) == '%') {
            stBuff.setCharAt(i, '.');
            stBuff.insert(i + 1, '*');
            i++;
          }
        }
        stBuff.append('$');

        st = stBuff.toString();
        RESULT = new Boolean(Pattern.matches(st, (String) Interpreter.interpret(id, message, syntaxType)));
      }
      // Comparison of non like values returns FALSE.
      else
        RESULT = Boolean.FALSE;

      CUP$Filter$result = new java_cup.runtime.Symbol(2/* comp_expr */,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 2)).left,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).right, RESULT);
    }
      return CUP$Filter$result;

      /* . . . . . . . . . . . . . . . . . . . . */
    case 15: // comp_expr ::= ID NOT IN LPAREN strings RPAREN
    {
      Boolean RESULT = null;
      String id = (String) ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 5)).value;
      String sts = (String) ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 1)).value;

      Object value = Interpreter.interpret(id, message, syntaxType);
      if (value == null)
        RESULT = null;

      else if (value instanceof String) {
        StringTokenizer st = new StringTokenizer(sts, "\b");
        boolean match = true;
        while (st.hasMoreTokens()) {
          String current = st.nextToken();
          if (current.equals(value)) {
            match = false;
            break;
          }
        }
        RESULT = new Boolean(match);

        // Comparison of non like values returns FALSE.
      } else
        RESULT = Boolean.FALSE;

      CUP$Filter$result = new java_cup.runtime.Symbol(2/* comp_expr */,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 5)).left,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).right, RESULT);
    }
      return CUP$Filter$result;

      /* . . . . . . . . . . . . . . . . . . . . */
    case 14: // comp_expr ::= ID IN LPAREN strings RPAREN
    {
      Boolean RESULT = null;
      String id = (String) ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 4)).value;
      String sts = (String) ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 1)).value;

      Object value = Interpreter.interpret(id, message, syntaxType);
      if (value == null)
        RESULT = null;

      else if (value instanceof String) {
        StringTokenizer st = new StringTokenizer(sts, "\b");
        boolean match = false;
        while (st.hasMoreTokens()) {
          String current = st.nextToken();
          if (current.equals(value)) {
            match = true;
            break;
          }
        }
        RESULT = new Boolean(match);
        // Comparison of non like values returns FALSE.
      } else
        RESULT = Boolean.FALSE;

      CUP$Filter$result = new java_cup.runtime.Symbol(2/* comp_expr */,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 4)).left,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).right, RESULT);
    }
      return CUP$Filter$result;

      /* . . . . . . . . . . . . . . . . . . . . */
    case 13: // comp_expr ::= expr NOTBETWEEN expr AND expr
    {
      Boolean RESULT = null;
      Object e1 = ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 4)).value;
      Object e2 = ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 2)).value;
      Object e3 = ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).value;

      if (e1 == null || e2 == null || e3 == null)
        RESULT = null;

      else if (e1 instanceof Number && e2 instanceof Number && e3 instanceof Number)
        RESULT = new Boolean((((Number) e1).doubleValue() < ((Number) e2).doubleValue())
            || (((Number) e1).doubleValue() > ((Number) e3).doubleValue()));

      // Comparison of non like values returns FALSE.
      else
        RESULT = Boolean.FALSE;

      CUP$Filter$result = new java_cup.runtime.Symbol(2/* comp_expr */,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 4)).left,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).right, RESULT);
    }
      return CUP$Filter$result;

      /* . . . . . . . . . . . . . . . . . . . . */
    case 12: // comp_expr ::= expr BETWEEN expr AND expr
    {
      Boolean RESULT = null;
      Object e1 = ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 4)).value;
      Object e2 = ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 2)).value;
      Object e3 = ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).value;

      if (e1 == null || e2 == null || e3 == null)
        RESULT = null;

      else if (e1 instanceof Number && e2 instanceof Number && e3 instanceof Number)
        RESULT = new Boolean((((Number) e1).doubleValue() >= ((Number) e2).doubleValue())
            && (((Number) e1).doubleValue() <= ((Number) e3).doubleValue()));

      // Comparison of non like values returns FALSE.
      else
        RESULT = Boolean.FALSE;

      CUP$Filter$result = new java_cup.runtime.Symbol(2/* comp_expr */,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 4)).left,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).right, RESULT);
    }
      return CUP$Filter$result;

      /* . . . . . . . . . . . . . . . . . . . . */
    case 11: // comp_expr ::= expr NEQ expr
    {
      Boolean RESULT = null;
      Object e1 = ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 2)).value;
      Object e2 = ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).value;

      if (e1 == null || e2 == null)
        RESULT = null;

      else if (e1 instanceof Number && e2 instanceof Number)
        RESULT = new Boolean(((Number) e1).doubleValue() != ((Number) e2).doubleValue());

      else if (e1 instanceof Boolean && e2 instanceof Boolean)
        RESULT = new Boolean(!((Boolean) e1).equals((Boolean) e2));

      else if (e1 instanceof String && e2 instanceof String)
        RESULT = new Boolean(!((String) e1).equals((String) e2));

      else if (e1 instanceof Boolean && e2 instanceof Number)
        RESULT = new Boolean(
            !((((Boolean) e1).booleanValue() == true) ? (((Number) e2).doubleValue() == 0) ? true : false
                : (((Number) e2).doubleValue() != 0) ? true : false));

      else if (e1 instanceof Number && e2 instanceof Boolean)
        RESULT = new Boolean(
            !((((Boolean) e2).booleanValue() == true) ? (((Number) e1).doubleValue() == 0) ? true : false
                : (((Number) e1).doubleValue() != 0) ? true : false));

      // Comparison of non like values returns FALSE.
      else
        RESULT = Boolean.FALSE;

      CUP$Filter$result = new java_cup.runtime.Symbol(2/* comp_expr */,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 2)).left,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).right, RESULT);
    }
      return CUP$Filter$result;

      /* . . . . . . . . . . . . . . . . . . . . */
    case 10: // comp_expr ::= expr EQ expr
    {
      Boolean RESULT = null;
      Object e1 = ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 2)).value;
      Object e2 = ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).value;

      if (e1 == null || e2 == null)
        RESULT = null;

      else if (e1 instanceof Number && e2 instanceof Number)
        RESULT = new Boolean(((Number) e1).doubleValue() == ((Number) e2).doubleValue());

      else if (e1 instanceof Boolean && e2 instanceof Boolean)
        RESULT = new Boolean(((Boolean) e1).equals((Boolean) e2));

      else if (e1 instanceof String && e2 instanceof String)
        RESULT = new Boolean(((String) e1).equals((String) e2));

      else if (e1 instanceof Boolean && e2 instanceof Number)
        RESULT = new Boolean(
            (((Boolean) e1).booleanValue() == true) ? (((Number) e2).doubleValue() == 0) ? true : false
                : (((Number) e2).doubleValue() != 0) ? true : false);

      else if (e1 instanceof Number && e2 instanceof Boolean)
        RESULT = new Boolean(
            (((Boolean) e2).booleanValue() == true) ? (((Number) e1).doubleValue() == 0) ? true : false
                : (((Number) e1).doubleValue() != 0) ? true : false);

      // Comparison of non like values returns FALSE.
      else
        RESULT = Boolean.FALSE;

      CUP$Filter$result = new java_cup.runtime.Symbol(2/* comp_expr */,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 2)).left,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).right, RESULT);
    }
      return CUP$Filter$result;

      /* . . . . . . . . . . . . . . . . . . . . */
    case 9: // comp_expr ::= expr LE expr
    {
      Boolean RESULT = null;
      Object e1 = ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 2)).value;
      Object e2 = ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).value;

      if (e1 == null || e2 == null)
        RESULT = null;

      else if (e1 instanceof Number && e2 instanceof Number)
        RESULT = new Boolean(((Number) e1).doubleValue() <= ((Number) e2).doubleValue());

      // Comparison of non like values returns FALSE.
      else
        RESULT = Boolean.FALSE;

      CUP$Filter$result = new java_cup.runtime.Symbol(2/* comp_expr */,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 2)).left,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).right, RESULT);
    }
      return CUP$Filter$result;

      /* . . . . . . . . . . . . . . . . . . . . */
    case 8: // comp_expr ::= expr LT expr
    {
      Boolean RESULT = null;
      Object e1 = ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 2)).value;
      Object e2 = ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).value;

      if (e1 == null || e2 == null)
        RESULT = null;

      else if (e1 instanceof Number && e2 instanceof Number)
        RESULT = new Boolean(((Number) e1).doubleValue() < ((Number) e2).doubleValue());

      // Comparison of non like values returns FALSE.
      else
        RESULT = Boolean.FALSE;

      CUP$Filter$result = new java_cup.runtime.Symbol(2/* comp_expr */,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 2)).left,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).right, RESULT);
    }
      return CUP$Filter$result;

      /* . . . . . . . . . . . . . . . . . . . . */
    case 7: // comp_expr ::= expr GE expr
    {
      Boolean RESULT = null;
      Object e1 = ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 2)).value;
      Object e2 = ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).value;

      if (e1 == null || e2 == null)
        RESULT = null;

      else if (e1 instanceof Number && e2 instanceof Number)
        RESULT = new Boolean(((Number) e1).doubleValue() >= ((Number) e2).doubleValue());

      // Comparison of non like values returns FALSE.
      else
        RESULT = Boolean.FALSE;

      CUP$Filter$result = new java_cup.runtime.Symbol(2/* comp_expr */,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 2)).left,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).right, RESULT);
    }
      return CUP$Filter$result;

      /* . . . . . . . . . . . . . . . . . . . . */
    case 6: // comp_expr ::= expr GT expr
    {
      Boolean RESULT = null;
      Object e1 = ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 2)).value;
      Object e2 = ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).value;

      if (e1 == null || e2 == null)
        RESULT = null;

      else if (e1 instanceof Number && e2 instanceof Number)
        RESULT = new Boolean(((Number) e1).doubleValue() > ((Number) e2).doubleValue());

      // Comparison of non like values returns FALSE.
      else
        RESULT = Boolean.FALSE;

      CUP$Filter$result = new java_cup.runtime.Symbol(2/* comp_expr */,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 2)).left,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).right, RESULT);
    }
      return CUP$Filter$result;

      /* . . . . . . . . . . . . . . . . . . . . */
    case 5: // comp_expr ::= LPAREN cond_expr RPAREN
    {
      Boolean RESULT = null;
      Boolean cond = (Boolean) ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 1)).value;

      RESULT = cond;

      CUP$Filter$result = new java_cup.runtime.Symbol(2/* comp_expr */,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 2)).left,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).right, RESULT);
    }
      return CUP$Filter$result;

      /* . . . . . . . . . . . . . . . . . . . . */
    case 4: // cond_expr ::= comp_expr
    {
      Boolean RESULT = null;
      Boolean comp = (Boolean) ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).value;

      RESULT = comp;

      CUP$Filter$result = new java_cup.runtime.Symbol(1/* cond_expr */,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).left,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).right, RESULT);
    }
      return CUP$Filter$result;

      /* . . . . . . . . . . . . . . . . . . . . */
    case 3: // cond_expr ::= NOT cond_expr
    {
      Boolean RESULT = null;
      Boolean cond = (Boolean) ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).value;

      if (cond != null)
        RESULT = new Boolean(!cond.booleanValue());

      else
        RESULT = Boolean.FALSE;

      CUP$Filter$result = new java_cup.runtime.Symbol(1/* cond_expr */,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 1)).left,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).right, RESULT);
    }
      return CUP$Filter$result;

      /* . . . . . . . . . . . . . . . . . . . . */
    case 2: // cond_expr ::= cond_expr AND cond_expr
    {
      Boolean RESULT = null;
      Boolean cond1 = (Boolean) ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 2)).value;
      Boolean cond2 = (Boolean) ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).value;

      if (cond1 != null && cond2 != null)
        RESULT = new Boolean(cond1.booleanValue() && cond2.booleanValue());

      else
        RESULT = Boolean.FALSE;

      CUP$Filter$result = new java_cup.runtime.Symbol(1/* cond_expr */,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 2)).left,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).right, RESULT);
    }
      return CUP$Filter$result;

      /* . . . . . . . . . . . . . . . . . . . . */
    case 1: // $START ::= cond_expr EOF
    {
      Object RESULT = null;
      Boolean start_val = (Boolean) ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 1)).value;
      RESULT = start_val;
      CUP$Filter$result = new java_cup.runtime.Symbol(0/* $START */,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 1)).left,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).right, RESULT);
    }
      /* ACCEPT */
      CUP$Filter$parser.done_parsing();
      return CUP$Filter$result;

      /* . . . . . . . . . . . . . . . . . . . . */
    case 0: // cond_expr ::= cond_expr OR cond_expr
    {
      Boolean RESULT = null;
      Boolean cond1 = (Boolean) ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 2)).value;
      Boolean cond2 = (Boolean) ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).value;

      if (cond1 != null && cond2 != null)
        RESULT = new Boolean(cond1.booleanValue() || cond2.booleanValue());

      else if (cond1 == null && cond2 != null)
        RESULT = cond2;

      else if (cond1 != null && cond2 == null)
        RESULT = cond1;

      else
        RESULT = Boolean.FALSE;

      CUP$Filter$result = new java_cup.runtime.Symbol(1/* cond_expr */,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 2)).left,
          ((java_cup.runtime.Symbol) CUP$Filter$stack.elementAt(CUP$Filter$top - 0)).right, RESULT);
    }
      return CUP$Filter$result;

      /* . . . . . . */
    default:
      throw new Exception("Invalid action number found in internal parse table");

    }
  }
}
TOP

Related Classes of org.objectweb.joram.shared.selectors.CUP$Filter$actions

TOP
Copyright © 2018 www.massapi.com. 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.