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 __domGlsl_setparam_simple_h__ 10 #define __domGlsl_setparam_simple_h__ 11 12 #include <dae/daeDocument.h> 13 #include <dom/domTypes.h> 14 #include <dom/domElements.h> 15 16 #include <dom/domGlsl_param_type.h> 17 #include <dom/domFx_annotate_common.h> 18 class DAE; 19 20 class domGlsl_setparam_simple_complexType 21 { 22 protected: // Attribute 23 domGlsl_identifier attrRef; 24 25 protected: // Elements 26 domFx_annotate_common_Array elemAnnotate_array; 27 domGlsl_param_typeRef elemGlsl_param_type; 28 29 public: //Accessors and Mutators 30 /** 31 * Gets the ref attribute. 32 * @return Returns a domGlsl_identifier of the ref attribute. 33 */ 34 domGlsl_identifier getRef() const { return attrRef; } 35 /** 36 * Sets the ref attribute. 37 * @param atRef The new value for the ref attribute. 38 */ 39 void setRef( domGlsl_identifier atRef ) { attrRef = atRef; } 40 41 /** 42 * Gets the annotate element array. 43 * @return Returns a reference to the array of annotate elements. 44 */ 45 domFx_annotate_common_Array &getAnnotate_array() { return elemAnnotate_array; } 46 /** 47 * Gets the annotate element array. 48 * @return Returns a constant reference to the array of annotate elements. 49 */ 50 const domFx_annotate_common_Array &getAnnotate_array() const { return elemAnnotate_array; } 51 /** 52 * Gets the glsl_param_type element. 53 * @return a daeSmartRef to the glsl_param_type element. 54 */ 55 const domGlsl_param_typeRef getGlsl_param_type() const { return elemGlsl_param_type; } 56 protected: 57 /** 58 * Constructor 59 */ 60 domGlsl_setparam_simple_complexType(DAE& dae, daeElement* elt) : attrRef(), elemAnnotate_array(), elemGlsl_param_type() {} 61 /** 62 * Destructor 63 */ 64 virtual ~domGlsl_setparam_simple_complexType() {} 65 /** 66 * Overloaded assignment operator 67 */ 68 virtual domGlsl_setparam_simple_complexType &operator=( const domGlsl_setparam_simple_complexType &cpy ) { (void)cpy; return *this; } 69 }; 70 71 /** 72 * An element of type domGlsl_setparam_simple_complexType. 73 */ 74 class domGlsl_setparam_simple : public daeElement, public domGlsl_setparam_simple_complexType 75 { 76 public: 77 virtual COLLADA_TYPE::TypeEnum getElementType() const { return COLLADA_TYPE::GLSL_SETPARAM_SIMPLE; } 78 static daeInt ID() { return 111; } 79 virtual daeInt typeID() const { return ID(); } 80 81 public: //Accessors and Mutators 82 /** 83 * Gets the ref attribute. 84 * @return Returns a domGlsl_identifier of the ref attribute. 85 */ 86 domGlsl_identifier getRef() const { return attrRef; } 87 /** 88 * Sets the ref attribute. 89 * @param atRef The new value for the ref attribute. 90 */ 91 void setRef( domGlsl_identifier atRef ) { attrRef = atRef; _validAttributeArray[0] = true; } 92 93 protected: 94 /** 95 * Constructor 96 */ 97 domGlsl_setparam_simple(DAE& dae) : daeElement(dae), domGlsl_setparam_simple_complexType(dae, this) {} 98 /** 99 * Destructor 100 */ 101 virtual ~domGlsl_setparam_simple() {} 102 /** 103 * Overloaded assignment operator 104 */ 105 virtual domGlsl_setparam_simple &operator=( const domGlsl_setparam_simple &cpy ) { (void)cpy; return *this; } 106 107 public: // STATIC METHODS 108 /** 109 * Creates an instance of this class and returns a daeElementRef referencing it. 110 * @return a daeElementRef referencing an instance of this object. 111 */ 112 static DLLSPEC daeElementRef create(DAE& dae); 113 /** 114 * Creates a daeMetaElement object that describes this element in the meta object reflection framework. 115 * If a daeMetaElement already exists it will return that instead of creating a new one. 116 * @return A daeMetaElement describing this COLLADA element. 117 */ 118 static DLLSPEC daeMetaElement* registerElement(DAE& dae); 119 }; 120 121 122 #endif 123