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