package edu.uabc.ai.search;

public class State {
    public final Object value;

    public State(Object value) {
        if (value == null) 
            throw new RuntimeException("State value cannot be null");

        this.value = value;
    }
    
    @Override
    public String toString() {
        return String.format("S(%s)", this.value.toString());
    }

    @Override
    public boolean equals(Object o) {
        if (o == null || !(o instanceof State))
            return false;

        return this.value.equals(((State)o).value);
    }
}

@@ -544,11 +544,609 @@
 );%0A    %7D
+%0A%0A    /**%0A     *  Convenience function to create states.%0A     *  @param v The value of the state%0A     *  @param The created state%0A     */%0A    public static State S(Object v) %7B%0A        return new State(v);%0A    %7D%0A%0A    /**%0A     * Convenience function to create a set of states.%0A     *%0A     * @param vs The values of each state.%0A     * @return An array containing the created states.%0A     */%0A    public static State%5B%5D States(Object ... vs) %7B%0A        State ss%5B%5D= new State%5Bvs.length%5D;%0A        for(int i= 0; i%3Cvs.length; i++)%0A            ss%5Bi%5D= new State(vs%5Bi%5D);%0A                %0A        return ss;%0A    %7D
 %0A%7D%0A

Add convenience functions to the State class