this.constants=constants;
    public Object visitSwitchStatement(JSwitchStatement self,                                       JExpression expr,                                       JSwitchGroup[] body) {        if(!write) {            expr.accept(this);            for(int i = 0; i < body.length; i++) {                body[i].accept(this);            }        } else {            JExpression newExp = (JExpression)expr.accept(this);            // reset if constant            if (newExp!=expr) {                self.setExpression(newExp);            }            Propagator[] propagators=new Propagator[body.length];            for (int i = 0; i < body.length; i++) {                Set varsToClone = getFreeVars(body[i]);                // include free var from <expr> for proper comparison with <origConstants> below                varsToClone.addAll(getFreeVars(expr));                Propagator prop=construct(cloneTable(constants, varsToClone),true);                propagators[i]=prop;                body[i].accept(prop);            }            if(body.length>0) {                Hashtable newConstants=propagators[0].constants; //Shadow the main constants                //Remove if value is not same in all switch bodies                for(int i=1;i<propagators.length;i++) {                    Propagator prop=propagators[i];                    LinkedList remove=new LinkedList();                    Enumeration eNum=newConstants.keys();                    while(eNum.hasMoreElements()) {                        Object key=eNum.nextElement();                        if(!(prop.constants.get(key).equals(newConstants.get(key))))                            remove.add(key);                        if((prop.constants.get(key) instanceof Object[])&&(newConstants.get(key) instanceof Object[])) {                            Object[] array1=(Object[])prop.constants.get(key);                            Object[] array2=(Object[])newConstants.get(key);                            if(array1.length!=array2.length)                                remove.add(key);                            else                                for(int j=0;j<array1.length;j++)                                    if(((array1[j]!=array2[j])&&(array1[j]!=null)&&(!array1[j].equals(array2[j]))))                                        remove.add(key);                        }                    }                    for(int j=0;j<remove.size();j++) {                        newConstants.remove(remove.get(j));                    }                }                // mark anything that's in <newConstants> but not in                // <constants> as <changed>                Hashtable origConstants = cloneTable(constants, getFreeVars(self));                for (Enumeration e=origConstants.keys(); e.hasMoreElements(); ) {                    Object key=e.nextElement();                    if (!newConstants.containsKey(key)) {                        changed.put(key, Boolean.TRUE);                        constants.remove(key);                    } else {                        constants.put(key, newConstants.get(key));                    }                }                this.constants=constants;            }        }        return self;    }