Start line:  
End line:  

Snippet Preview

Snippet HTML Code

Stack Overflow Questions
 
 package org.virtualbox_4_2.jaxws;
 

Java class for AutostopType.

The following schema fragment specifies the expected content contained within this class.

 <simpleType name="AutostopType">
   <restriction base="{http://www.w3.org/2001/XMLSchema}string">
     <enumeration value="Disabled"/>
     <enumeration value="SaveState"/>
     <enumeration value="PowerOff"/>
     <enumeration value="AcpiShutdown"/>
   </restriction>
 </simpleType>
 
@XmlType(name = "AutostopType")
public enum AutostopType {
    @XmlEnumValue("Disabled")
    DISABLED("Disabled"),
    @XmlEnumValue("SaveState")
    SAVE_STATE("SaveState"),
    @XmlEnumValue("PowerOff")
    POWER_OFF("PowerOff"),
    @XmlEnumValue("AcpiShutdown")
    ACPI_SHUTDOWN("AcpiShutdown");
    private final String value;
    AutostopType(String v) {
         = v;
    }
    public String value() {
        return ;
    }
    public static AutostopType fromValue(String v) {
        for (AutostopType c: AutostopType.values()) {
            if (c.value.equals(v)) {
                return c;
            }
        }
        throw new IllegalArgumentException(v);
    }
New to GrepCode? Check out our FAQ X