
    
package performa.orm.types;

import java.util.*;
import oneit.utils.*;



/**
 * This class was generated using constGen.bat.
 * DO NOT MODIFY THIS CODE.
 * Edit the associated .xml file, and regenerate this file
 * constGen (directory) (file minus extension)
 * e.g. constGen C:\...\sql FieldType
 */

public class LocationRadius extends AbstractEnumerated
{
    
    public static final EnumeratedFactory FACTORY_LocationRadius = new LocationRadiusFactory();
    
    public static final LocationRadius KM100 = new LocationRadius ("KM100", "KM100", "100 km", false);

    private static final LocationRadius[] allLocationRadiuss =
        new LocationRadius[] { KM100};


    private static LocationRadius[] getAllLocationRadiuss ()
    {
        return allLocationRadiuss;
    }

    private LocationRadius (String name, String value, String description, boolean disabled)
    {
        super (name, value, description, disabled);
    }
    
    public static final Comparator COMPARE_BY_POSITION = new CompareEnumByPosition (allLocationRadiuss);



    static
    {
        defineAdditionalData ();
    }

    public boolean isEqual (LocationRadius other)
    {
    return this.name.equals (other.name);
    }

    public Enumeration getAllInstances ()
    {
        return LocationRadius.getAll ();
    }


    private Object readResolve() throws java.io.ObjectStreamException
    {
        return LocationRadius.forName (this.name);
    }


    public EnumeratedFactory getFactory ()
    {
        return FACTORY_LocationRadius;
    }

    public static LocationRadius forName (String name)
    {
        if (name == null) { return null; }

        LocationRadius[] all = getAllLocationRadiuss();
        int enumIndex = AbstractEnumerated.getIndexForName (all, name);

        return all[enumIndex];
    }


    public static LocationRadius forValue (String value)
    {
        if (value == null) { return null; }

        LocationRadius[] all = getAllLocationRadiuss();
        int enumIndex = AbstractEnumerated.getIndexForValue (getAllLocationRadiuss (), value);

        return all[enumIndex];
    }


    public static java.util.Enumeration getAll ()
    {
        return AbstractEnumerated.getAll (getAllLocationRadiuss());
    }
    
    
    public static LocationRadius[] getLocationRadiusArray ()
    {
        return (LocationRadius[])getAllLocationRadiuss().clone ();
    }


    public static void defineAdditionalData ()
    {
        
    }


    static class LocationRadiusFactory implements EnumeratedFactory
    {
        public AbstractEnumerated getForName (String name)
        {
            return LocationRadius.forName (name);
        }

        public AbstractEnumerated getForValue (String name)
        {
            return LocationRadius.forValue (name);
        }

        public Enumeration getAll ()
        {
            return LocationRadius.getAll ();
        }
    }


    public Map getAdditionalAttributes ()
    {
        Map attribs = new HashMap ();

        
        return attribs;
    }
}

