00001 // This file may be redistributed and modified only under the terms of 00002 // the GNU Lesser General Public License (See COPYING for details). 00003 // Copyright 2000-2001 Stefanus Du Toit and Alistair Riddoch. 00004 // Automatically generated using gen_cc.py. 00005 00006 #ifndef ATLAS_OBJECTS_ENTITY_ROOTENTITY_H 00007 #define ATLAS_OBJECTS_ENTITY_ROOTENTITY_H 00008 00009 #include <Atlas/Objects/Root.h> 00010 00011 00012 namespace Atlas { namespace Objects { namespace Entity { 00013 00019 class RootEntity : public Root 00020 { 00021 public: 00023 RootEntity(); 00024 protected: 00025 RootEntity(const std::string&,const std::string&); 00026 public: 00028 virtual ~RootEntity(); 00029 00031 static RootEntity Instantiate(); 00032 00034 virtual bool HasAttr(const std::string& name)const; 00037 virtual Atlas::Message::Object GetAttr(const std::string& name) 00038 const throw (NoSuchAttrException); 00040 virtual void SetAttr(const std::string& name, 00041 const Atlas::Message::Object& attr); 00043 virtual void RemoveAttr(const std::string& name); 00044 00046 virtual void SendContents(Atlas::Bridge* b) const; 00047 00049 virtual Atlas::Message::Object AsObject() const; 00050 00052 virtual Atlas::Message::Object::MapType AsMap() const; 00053 00055 inline void SetLoc(const std::string& val); 00057 inline void SetPos(const Atlas::Message::Object::ListType& val); 00059 inline void SetVelocity(const Atlas::Message::Object::ListType& val); 00061 inline void SetContains(const Atlas::Message::Object::ListType& val); 00063 inline void SetStampContains(double val); 00064 00066 inline const std::string& GetLoc() const; 00068 inline std::string& GetLoc(); 00070 inline const Atlas::Message::Object::ListType& GetPos() const; 00072 inline Atlas::Message::Object::ListType& GetPos(); 00074 inline const Atlas::Message::Object::ListType& GetVelocity() const; 00076 inline Atlas::Message::Object::ListType& GetVelocity(); 00078 inline const Atlas::Message::Object::ListType& GetContains() const; 00080 inline Atlas::Message::Object::ListType& GetContains(); 00082 inline double GetStampContains() const; 00084 inline double& GetStampContains(); 00085 00086 protected: 00087 std::string attr_loc; 00088 Atlas::Message::Object::ListType attr_pos; 00089 Atlas::Message::Object::ListType attr_velocity; 00090 Atlas::Message::Object::ListType attr_contains; 00091 double attr_stamp_contains; 00092 00093 inline void SendLoc(Atlas::Bridge*) const; 00094 inline void SendPos(Atlas::Bridge*) const; 00095 inline void SendVelocity(Atlas::Bridge*) const; 00096 inline void SendContains(Atlas::Bridge*) const; 00097 inline void SendStampContains(Atlas::Bridge*) const; 00098 00099 }; 00100 00101 // 00102 // Inlined member functions follow. 00103 // 00104 00105 void RootEntity::SetLoc(const std::string& val) 00106 { 00107 attr_loc = val; 00108 } 00109 00110 void RootEntity::SetPos(const Atlas::Message::Object::ListType& val) 00111 { 00112 attr_pos = val; 00113 } 00114 00115 void RootEntity::SetVelocity(const Atlas::Message::Object::ListType& val) 00116 { 00117 attr_velocity = val; 00118 } 00119 00120 void RootEntity::SetContains(const Atlas::Message::Object::ListType& val) 00121 { 00122 attr_contains = val; 00123 } 00124 00125 void RootEntity::SetStampContains(double val) 00126 { 00127 attr_stamp_contains = val; 00128 } 00129 00130 const std::string& RootEntity::GetLoc() const 00131 { 00132 return attr_loc; 00133 } 00134 00135 std::string& RootEntity::GetLoc() 00136 { 00137 return attr_loc; 00138 } 00139 00140 const Atlas::Message::Object::ListType& RootEntity::GetPos() const 00141 { 00142 return attr_pos; 00143 } 00144 00145 Atlas::Message::Object::ListType& RootEntity::GetPos() 00146 { 00147 return attr_pos; 00148 } 00149 00150 const Atlas::Message::Object::ListType& RootEntity::GetVelocity() const 00151 { 00152 return attr_velocity; 00153 } 00154 00155 Atlas::Message::Object::ListType& RootEntity::GetVelocity() 00156 { 00157 return attr_velocity; 00158 } 00159 00160 const Atlas::Message::Object::ListType& RootEntity::GetContains() const 00161 { 00162 return attr_contains; 00163 } 00164 00165 Atlas::Message::Object::ListType& RootEntity::GetContains() 00166 { 00167 return attr_contains; 00168 } 00169 00170 double RootEntity::GetStampContains() const 00171 { 00172 return attr_stamp_contains; 00173 } 00174 00175 double& RootEntity::GetStampContains() 00176 { 00177 return attr_stamp_contains; 00178 } 00179 00180 00181 } } } // namespace Atlas::Objects::Entity 00182 00183 #endif // ATLAS_OBJECTS_ENTITY_ROOTENTITY_H
Copyright 2000 the respective authors.
This document is licensed under the terms of the GNU Free Documentation License and may be freely distributed under the conditions given by this license.