00001 00009 #pragma once 00010 00011 #include "ManagedObject.h" 00012 #include "WDError.h" 00013 00014 class Formation; 00015 class Actor; 00016 00024 class ActorRef: public ManagedObject 00025 { 00026 private: 00027 Actor *mActor; //*!< Actor being referenced */ 00028 00029 protected: 00033 WDError updateActorID(); 00034 00035 public: 00036 ActorRef(); 00037 ~ActorRef(); 00038 00044 WDError initRef(void *inNode, IObjectManager *inManager, IObjectEventHandler *inEventHandler); 00045 00051 WDError initRef(Formation *inParent, int inIndex, IObjectEventHandler *inEventHandler); 00052 00058 WDError initNew(Formation *inParent, Actor *inActor, IObjectEventHandler *inEventHandler); 00059 00063 WDError setActor(void *inActor); 00064 00068 WDError getActor(void **outActorNode); 00069 00074 WDError getActorName(char *outActorName, int inMaxLength); 00075 00076 // IObjectEventHandler Interface // 00077 void childChanged(IManagedObject *inTarget, void *inChild); 00078 };