/**
 * cg_fixed1.java This file was generated by XMLSpy 2006sp2 Enterprise Edition.
 * YOU SHOULD NOT MODIFY THIS FILE, BECAUSE IT WILL BE OVERWRITTEN WHEN YOU
 * RE-RUN CODE GENERATION. Refer to the XMLSpy Documentation for further
 * details. http://www.altova.com/xmlspy
 */

package com.jmex.model.collada.schema;

import com.jmex.model.collada.types.SchemaFloat;

public class cg_fixed1 extends SchemaFloat {

    private static final long serialVersionUID = 1L;

    public cg_fixed1() {
        super();
    }

    public cg_fixed1(String newValue) {
        super(newValue);
        validate();
    }

    public cg_fixed1(SchemaFloat newValue) {
        super(newValue);
        validate();
    }

    public void validate() {

        if (compareTo(getMaxInclusive()) > 0)
            throw new com.jmex.model.collada.xml.XmlException(
                    "Value of cg_fixed1 is out of range.");

        if (compareTo(getMinInclusive()) < 0)
            throw new com.jmex.model.collada.xml.XmlException(
                    "Value of cg_fixed1 is out of range.");
    }

    public SchemaFloat getMaxInclusive() {
        return new SchemaFloat("2.0");
    }

    public SchemaFloat getMinInclusive() {
        return new SchemaFloat("-2.0");
    }
}
