/**
 * technique_commonType6.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;

public class technique_commonType6 extends com.jmex.model.collada.xml.Node {

    private static final long serialVersionUID = 1L;

    public technique_commonType6(technique_commonType6 node) {
        super(node);
    }

    public technique_commonType6(org.w3c.dom.Node node) {
        super(node);
    }

    public technique_commonType6(org.w3c.dom.Document doc) {
        super(doc);
    }

    public technique_commonType6(com.jmex.model.collada.xml.Document doc,
            String namespaceURI, String prefix, String name) {
        super(doc, namespaceURI, prefix, name);
    }

    public void adjustPrefix() {
        for (org.w3c.dom.Node tmpNode = getDomFirstChild(Element,
                "http://www.collada.org/2005/11/COLLADASchema", "gravity"); tmpNode != null; tmpNode = getDomNextChild(
                Element, "http://www.collada.org/2005/11/COLLADASchema",
                "gravity", tmpNode)) {
            internalAdjustPrefix(tmpNode, true);
            new TargetableFloat3(tmpNode).adjustPrefix();
        }
        for (org.w3c.dom.Node tmpNode = getDomFirstChild(Element,
                "http://www.collada.org/2005/11/COLLADASchema", "time_step"); tmpNode != null; tmpNode = getDomNextChild(
                Element, "http://www.collada.org/2005/11/COLLADASchema",
                "time_step", tmpNode)) {
            internalAdjustPrefix(tmpNode, true);
            new TargetableFloat(tmpNode).adjustPrefix();
        }
    }

    public static int getgravityMinCount() {
        return 0;
    }

    public static int getgravityMaxCount() {
        return 1;
    }

    public int getgravityCount() {
        return getDomChildCount(Element,
                "http://www.collada.org/2005/11/COLLADASchema", "gravity");
    }

    public boolean hasgravity() {
        return hasDomChild(Element,
                "http://www.collada.org/2005/11/COLLADASchema", "gravity");
    }

    public TargetableFloat3 newgravity() {
        return new TargetableFloat3(domNode.getOwnerDocument().createElementNS(
                "http://www.collada.org/2005/11/COLLADASchema", "gravity"));
    }

    public TargetableFloat3 getgravityAt(int index) throws Exception {
        return new TargetableFloat3(dereference(getDomChildAt(Element,
                "http://www.collada.org/2005/11/COLLADASchema", "gravity",
                index)));
    }

    public org.w3c.dom.Node getStartinggravityCursor() throws Exception {
        return getDomFirstChild(Element,
                "http://www.collada.org/2005/11/COLLADASchema", "gravity");
    }

    public org.w3c.dom.Node getAdvancedgravityCursor(org.w3c.dom.Node curNode)
            throws Exception {
        return getDomNextChild(Element,
                "http://www.collada.org/2005/11/COLLADASchema", "gravity",
                curNode);
    }

    public TargetableFloat3 getgravityValueAtCursor(org.w3c.dom.Node curNode)
            throws Exception {
        if (curNode == null)
            throw new com.jmex.model.collada.xml.XmlException("Out of range");
        else
            return new TargetableFloat3(dereference(curNode));
    }

    public TargetableFloat3 getgravity() throws Exception {
        return getgravityAt(0);
    }

    public void removegravityAt(int index) {
        removeDomChildAt(Element,
                "http://www.collada.org/2005/11/COLLADASchema", "gravity",
                index);
    }

    public void removegravity() {
        while (hasgravity())
            removegravityAt(0);
    }

    public void addgravity(TargetableFloat3 value) {
        appendDomElement("http://www.collada.org/2005/11/COLLADASchema",
                "gravity", value);
    }

    public void insertgravityAt(TargetableFloat3 value, int index) {
        insertDomElementAt("http://www.collada.org/2005/11/COLLADASchema",
                "gravity", index, value);
    }

    public void replacegravityAt(TargetableFloat3 value, int index) {
        replaceDomElementAt("http://www.collada.org/2005/11/COLLADASchema",
                "gravity", index, value);
    }

    public static int gettime_stepMinCount() {
        return 0;
    }

    public static int gettime_stepMaxCount() {
        return 1;
    }

    public int gettime_stepCount() {
        return getDomChildCount(Element,
                "http://www.collada.org/2005/11/COLLADASchema", "time_step");
    }

    public boolean hastime_step() {
        return hasDomChild(Element,
                "http://www.collada.org/2005/11/COLLADASchema", "time_step");
    }

    public TargetableFloat newtime_step() {
        return new TargetableFloat(domNode.getOwnerDocument().createElementNS(
                "http://www.collada.org/2005/11/COLLADASchema", "time_step"));
    }

    public TargetableFloat gettime_stepAt(int index) throws Exception {
        return new TargetableFloat(dereference(getDomChildAt(Element,
                "http://www.collada.org/2005/11/COLLADASchema", "time_step",
                index)));
    }

    public org.w3c.dom.Node getStartingtime_stepCursor() throws Exception {
        return getDomFirstChild(Element,
                "http://www.collada.org/2005/11/COLLADASchema", "time_step");
    }

    public org.w3c.dom.Node getAdvancedtime_stepCursor(org.w3c.dom.Node curNode)
            throws Exception {
        return getDomNextChild(Element,
                "http://www.collada.org/2005/11/COLLADASchema", "time_step",
                curNode);
    }

    public TargetableFloat gettime_stepValueAtCursor(org.w3c.dom.Node curNode)
            throws Exception {
        if (curNode == null)
            throw new com.jmex.model.collada.xml.XmlException("Out of range");
        else
            return new TargetableFloat(dereference(curNode));
    }

    public TargetableFloat gettime_step() throws Exception {
        return gettime_stepAt(0);
    }

    public void removetime_stepAt(int index) {
        removeDomChildAt(Element,
                "http://www.collada.org/2005/11/COLLADASchema", "time_step",
                index);
    }

    public void removetime_step() {
        while (hastime_step())
            removetime_stepAt(0);
    }

    public void addtime_step(TargetableFloat value) {
        appendDomElement("http://www.collada.org/2005/11/COLLADASchema",
                "time_step", value);
    }

    public void inserttime_stepAt(TargetableFloat value, int index) {
        insertDomElementAt("http://www.collada.org/2005/11/COLLADASchema",
                "time_step", index, value);
    }

    public void replacetime_stepAt(TargetableFloat value, int index) {
        replaceDomElementAt("http://www.collada.org/2005/11/COLLADASchema",
                "time_step", index, value);
    }

    private org.w3c.dom.Node dereference(org.w3c.dom.Node node) {
        return node;
    }
}
