Home | History | Annotate | Download | only in dom
      1 /*
      2 * Copyright 2006 Sony Computer Entertainment Inc.
      3 *
      4 * Licensed under the MIT Open Source License, for details please see license.txt or the website
      5 * http://www.opensource.org/licenses/mit-license.php
      6 *
      7 */
      8 
      9 #ifndef __domGles_newparam_h__
     10 #define __domGles_newparam_h__
     11 
     12 #include <dae/daeDocument.h>
     13 #include <dom/domTypes.h>
     14 #include <dom/domElements.h>
     15 
     16 #include <dom/domGles_basic_type_common.h>
     17 #include <dom/domFx_annotate_common.h>
     18 class DAE;
     19 
     20 /**
     21  * Create a new, named param object in the GLES Runtime, assign it a type,
     22  * an initial value, and additional attributes at declaration time.
     23  */
     24 class domGles_newparam_complexType
     25 {
     26 public:
     27 	class domSemantic;
     28 
     29 	typedef daeSmartRef<domSemantic> domSemanticRef;
     30 	typedef daeTArray<domSemanticRef> domSemantic_Array;
     31 
     32 /**
     33  * The semantic element allows you to specify a semantic for this new param.
     34  */
     35 	class domSemantic : public daeElement
     36 	{
     37 	public:
     38 		virtual COLLADA_TYPE::TypeEnum getElementType() const { return COLLADA_TYPE::SEMANTIC; }
     39 		static daeInt ID() { return 165; }
     40 		virtual daeInt typeID() const { return ID(); }
     41 
     42 	protected:  // Value
     43 		/**
     44 		 * The xsNCName value of the text data of this element.
     45 		 */
     46 		xsNCName _value;
     47 
     48 	public:	//Accessors and Mutators
     49 		/**
     50 		 * Gets the value of this element.
     51 		 * @return Returns a xsNCName of the value.
     52 		 */
     53 		xsNCName getValue() const { return _value; }
     54 		/**
     55 		 * Sets the _value of this element.
     56 		 * @param val The new value for this element.
     57 		 */
     58 		void setValue( xsNCName val ) { *(daeStringRef*)&_value = val; }
     59 
     60 	protected:
     61 		/**
     62 		 * Constructor
     63 		 */
     64 		domSemantic(DAE& dae) : daeElement(dae), _value() {}
     65 		/**
     66 		 * Destructor
     67 		 */
     68 		virtual ~domSemantic() {}
     69 		/**
     70 		 * Overloaded assignment operator
     71 		 */
     72 		virtual domSemantic &operator=( const domSemantic &cpy ) { (void)cpy; return *this; }
     73 
     74 	public: // STATIC METHODS
     75 		/**
     76 		 * Creates an instance of this class and returns a daeElementRef referencing it.
     77 		 * @return a daeElementRef referencing an instance of this object.
     78 		 */
     79 		static DLLSPEC daeElementRef create(DAE& dae);
     80 		/**
     81 		 * Creates a daeMetaElement object that describes this element in the meta object reflection framework.
     82 		 * If a daeMetaElement already exists it will return that instead of creating a new one.
     83 		 * @return A daeMetaElement describing this COLLADA element.
     84 		 */
     85 		static DLLSPEC daeMetaElement* registerElement(DAE& dae);
     86 	};
     87 
     88 	class domModifier;
     89 
     90 	typedef daeSmartRef<domModifier> domModifierRef;
     91 	typedef daeTArray<domModifierRef> domModifier_Array;
     92 
     93 /**
     94  * The modifier element allows you to specify a modifier for this new param.
     95  */
     96 	class domModifier : public daeElement
     97 	{
     98 	public:
     99 		virtual COLLADA_TYPE::TypeEnum getElementType() const { return COLLADA_TYPE::MODIFIER; }
    100 		static daeInt ID() { return 166; }
    101 		virtual daeInt typeID() const { return ID(); }
    102 
    103 	protected:  // Value
    104 		/**
    105 		 * The domFx_modifier_enum_common value of the text data of this element.
    106 		 */
    107 		domFx_modifier_enum_common _value;
    108 
    109 	public:	//Accessors and Mutators
    110 		/**
    111 		 * Gets the value of this element.
    112 		 * @return a domFx_modifier_enum_common of the value.
    113 		 */
    114 		domFx_modifier_enum_common getValue() const { return _value; }
    115 		/**
    116 		 * Sets the _value of this element.
    117 		 * @param val The new value for this element.
    118 		 */
    119 		void setValue( domFx_modifier_enum_common val ) { _value = val; }
    120 
    121 	protected:
    122 		/**
    123 		 * Constructor
    124 		 */
    125 		domModifier(DAE& dae) : daeElement(dae), _value() {}
    126 		/**
    127 		 * Destructor
    128 		 */
    129 		virtual ~domModifier() {}
    130 		/**
    131 		 * Overloaded assignment operator
    132 		 */
    133 		virtual domModifier &operator=( const domModifier &cpy ) { (void)cpy; return *this; }
    134 
    135 	public: // STATIC METHODS
    136 		/**
    137 		 * Creates an instance of this class and returns a daeElementRef referencing it.
    138 		 * @return a daeElementRef referencing an instance of this object.
    139 		 */
    140 		static DLLSPEC daeElementRef create(DAE& dae);
    141 		/**
    142 		 * Creates a daeMetaElement object that describes this element in the meta object reflection framework.
    143 		 * If a daeMetaElement already exists it will return that instead of creating a new one.
    144 		 * @return A daeMetaElement describing this COLLADA element.
    145 		 */
    146 		static DLLSPEC daeMetaElement* registerElement(DAE& dae);
    147 	};
    148 
    149 
    150 protected:  // Attribute
    151 /**
    152  *  The sid attribute is a text string value containing the sub-identifier
    153  * of this element.  This value must be unique within the scope of the parent
    154  * element.
    155  */
    156 	xsNCName attrSid;
    157 
    158 protected:  // Elements
    159 /**
    160  * The annotate element allows you to specify an annotation for this new param.
    161  * @see domAnnotate
    162  */
    163 	domFx_annotate_common_Array elemAnnotate_array;
    164 /**
    165  * The semantic element allows you to specify a semantic for this new param.
    166  * @see domSemantic
    167  */
    168 	domSemanticRef elemSemantic;
    169 /**
    170  * The modifier element allows you to specify a modifier for this new param.
    171  * @see domModifier
    172  */
    173 	domModifierRef elemModifier;
    174 	domGles_basic_type_commonRef elemGles_basic_type_common;
    175 
    176 public:	//Accessors and Mutators
    177 	/**
    178 	 * Gets the sid attribute.
    179 	 * @return Returns a xsNCName of the sid attribute.
    180 	 */
    181 	xsNCName getSid() const { return attrSid; }
    182 	/**
    183 	 * Sets the sid attribute.
    184 	 * @param atSid The new value for the sid attribute.
    185 	 */
    186 	void setSid( xsNCName atSid ) { *(daeStringRef*)&attrSid = atSid;}
    187 
    188 	/**
    189 	 * Gets the annotate element array.
    190 	 * @return Returns a reference to the array of annotate elements.
    191 	 */
    192 	domFx_annotate_common_Array &getAnnotate_array() { return elemAnnotate_array; }
    193 	/**
    194 	 * Gets the annotate element array.
    195 	 * @return Returns a constant reference to the array of annotate elements.
    196 	 */
    197 	const domFx_annotate_common_Array &getAnnotate_array() const { return elemAnnotate_array; }
    198 	/**
    199 	 * Gets the semantic element.
    200 	 * @return a daeSmartRef to the semantic element.
    201 	 */
    202 	const domSemanticRef getSemantic() const { return elemSemantic; }
    203 	/**
    204 	 * Gets the modifier element.
    205 	 * @return a daeSmartRef to the modifier element.
    206 	 */
    207 	const domModifierRef getModifier() const { return elemModifier; }
    208 	/**
    209 	 * Gets the gles_basic_type_common element.
    210 	 * @return a daeSmartRef to the gles_basic_type_common element.
    211 	 */
    212 	const domGles_basic_type_commonRef getGles_basic_type_common() const { return elemGles_basic_type_common; }
    213 protected:
    214 	/**
    215 	 * Constructor
    216 	 */
    217 	domGles_newparam_complexType(DAE& dae, daeElement* elt) : attrSid(), elemAnnotate_array(), elemSemantic(), elemModifier(), elemGles_basic_type_common() {}
    218 	/**
    219 	 * Destructor
    220 	 */
    221 	virtual ~domGles_newparam_complexType() {}
    222 	/**
    223 	 * Overloaded assignment operator
    224 	 */
    225 	virtual domGles_newparam_complexType &operator=( const domGles_newparam_complexType &cpy ) { (void)cpy; return *this; }
    226 };
    227 
    228 /**
    229  * An element of type domGles_newparam_complexType.
    230  */
    231 class domGles_newparam : public daeElement, public domGles_newparam_complexType
    232 {
    233 public:
    234 	virtual COLLADA_TYPE::TypeEnum getElementType() const { return COLLADA_TYPE::GLES_NEWPARAM; }
    235 	static daeInt ID() { return 167; }
    236 	virtual daeInt typeID() const { return ID(); }
    237 
    238 public:	//Accessors and Mutators
    239 	/**
    240 	 * Gets the sid attribute.
    241 	 * @return Returns a xsNCName of the sid attribute.
    242 	 */
    243 	xsNCName getSid() const { return attrSid; }
    244 	/**
    245 	 * Sets the sid attribute.
    246 	 * @param atSid The new value for the sid attribute.
    247 	 */
    248 	void setSid( xsNCName atSid ) { *(daeStringRef*)&attrSid = atSid; _validAttributeArray[0] = true; }
    249 
    250 protected:
    251 	/**
    252 	 * Constructor
    253 	 */
    254 	domGles_newparam(DAE& dae) : daeElement(dae), domGles_newparam_complexType(dae, this) {}
    255 	/**
    256 	 * Destructor
    257 	 */
    258 	virtual ~domGles_newparam() {}
    259 	/**
    260 	 * Overloaded assignment operator
    261 	 */
    262 	virtual domGles_newparam &operator=( const domGles_newparam &cpy ) { (void)cpy; return *this; }
    263 
    264 public: // STATIC METHODS
    265 	/**
    266 	 * Creates an instance of this class and returns a daeElementRef referencing it.
    267 	 * @return a daeElementRef referencing an instance of this object.
    268 	 */
    269 	static DLLSPEC daeElementRef create(DAE& dae);
    270 	/**
    271 	 * Creates a daeMetaElement object that describes this element in the meta object reflection framework.
    272 	 * If a daeMetaElement already exists it will return that instead of creating a new one.
    273 	 * @return A daeMetaElement describing this COLLADA element.
    274 	 */
    275 	static DLLSPEC daeMetaElement* registerElement(DAE& dae);
    276 };
    277 
    278 
    279 #endif
    280