All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.xmlet.xsdparser.xsdelements.enums.UsageEnum Maven / Gradle / Ivy

package org.xmlet.xsdparser.xsdelements.enums;

import java.util.Arrays;
import java.util.List;

/**
 * An {@link Enum} with all the possible values for the usage attribute.
 */
public enum UsageEnum implements XsdEnum {

    REQUIRED ("required"),
    PROHIBITED ("prohibited"),
    OPTIONAL ("optional");

    private final String value;

    UsageEnum(String value) {
        this.value = value;
    }

    public String getValue() {
        return value;
    }

    @Override
    public String getVariableName() {
        return "use";
    }

    @Override
    public UsageEnum[] getValues() {
        return UsageEnum.values();
    }

    @Override
    public List getSupportedValues() {
        return Arrays.asList(REQUIRED.getValue(),
                             PROHIBITED.getValue(),
                             OPTIONAL.getValue());
    }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy