physicallayer/entity.h
00001 /* 00002 Crystal Space Entity Layer 00003 Copyright (C) 2001 by Jorrit Tyberghein 00004 00005 This library is free software; you can redistribute it and/or 00006 modify it under the terms of the GNU Library General Public 00007 License as published by the Free Software Foundation; either 00008 version 2 of the License, or (at your option) any later version. 00009 00010 This library is distributed in the hope that it will be useful, 00011 but WITHOUT ANY WARRANTY; without even the implied warranty of 00012 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 00013 Library General Public License for more details. 00014 00015 You should have received a copy of the GNU Library General Public 00016 License along with this library; if not, write to the Free 00017 Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. 00018 */ 00019 00020 #ifndef __CEL_PL_ENTITY__ 00021 #define __CEL_PL_ENTITY__ 00022 00023 #include "cstypes.h" 00024 #include "csutil/scf.h" 00025 #include "csutil/set.h" 00026 #include "csutil/strset.h" 00027 00028 struct iCelPropertyClassList; 00029 struct iCelBehaviour; 00030 struct iCelEntityIterator; 00031 struct iMessageChannel; 00032 struct iMessageDispatcher; 00033 struct iMessageSender; 00034 struct iObject; 00035 00047 struct iCelEntity : public virtual iBase 00048 { 00049 SCF_INTERFACE (iCelEntity, 0, 0, 3); 00055 virtual iObject* QueryObject () = 0; 00056 00061 virtual const char* GetName () const = 0; 00062 00067 virtual void SetName (const char* n) = 0; 00068 00073 virtual uint GetID () const = 0; 00074 00081 virtual void SetID (uint n) = 0; 00082 00088 virtual iCelPropertyClassList* GetPropertyClassList () = 0; 00089 00095 virtual void SetBehaviour (iCelBehaviour* behaviour) = 0; 00096 00102 virtual iCelBehaviour* GetBehaviour () = 0; 00103 00109 virtual void AddClass (csStringID cls) = 0; 00110 00114 virtual void RemoveClass (csStringID cls) = 0; 00115 00119 virtual bool HasClass (csStringID cls) = 0; 00120 00124 virtual const csSet<csStringID>& GetClasses () const = 0; 00125 00130 virtual iMessageChannel* QueryMessageChannel () = 0; 00131 00137 virtual csRef<iMessageDispatcher> CreateTaggedMessageDispatcher ( 00138 iMessageSender* sender, const char* msg_id, 00139 const char* tag) = 0; 00140 }; 00141 00150 struct iCelEntityList : public virtual iBase 00151 { 00152 SCF_INTERFACE (iCelEntityList, 0, 0, 2); 00153 00159 virtual size_t GetCount () const = 0; 00160 00169 virtual iCelEntity* Get (size_t n) const = 0; 00170 00179 virtual size_t Add (iCelEntity* obj) = 0; 00180 00189 virtual bool Remove (iCelEntity* obj) = 0; 00190 00199 virtual bool Remove (size_t n) = 0; 00200 00206 virtual void RemoveAll () = 0; 00207 00216 virtual size_t Find (iCelEntity* obj) const = 0; 00217 00226 virtual iCelEntity* FindByName (const char *Name) const = 0; 00227 00233 virtual csPtr<iCelEntityIterator> GetIterator () const = 0; 00234 }; 00235 00239 struct iCelEntityIterator : public virtual iBase 00240 { 00241 SCF_INTERFACE (iCelEntityIterator, 0, 0, 1); 00242 00246 virtual iCelEntity* Next () = 0; 00247 00251 virtual bool HasNext () const = 0; 00252 }; 00253 00254 #endif // __CEL_PL_ENTITY__ 00255
Generated for CEL: Crystal Entity Layer 1.4.1 by doxygen 1.7.1