/[usata]/usata2/src/object.hpp
ViewVC logotype

Diff of /usata2/src/object.hpp

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.6 by skunix, Sun Jan 2 06:34:43 2005 UTC revision 1.7 by skunix, Mon Jan 3 07:43:49 2005 UTC
# Line 47  namespace usata Line 47  namespace usata
47                  public:                  public:
48                          static  std::string NodePathPop(std::string&);                          static  std::string NodePathPop(std::string&);
49                          virtual void add_child(const Object_sp&, std::string& path){};                          virtual void add_child(const Object_sp&, std::string& path){};
50                            virtual void add_child(const Object_sp&){};
51                          virtual Object_sp get_child(const std::string&)=0;                          virtual Object_sp get_child(const std::string&)=0;
52    
53          };          };
54    
55          class Object          class Object
56          {          {
57                    Object*         Parent;
58                    std::string Name;
59                  public:                  public:
60                          virtual void    update(void) {};                          virtual void    update(void) {};
61                          virtual void    draw (void) {} ;                          virtual void    draw (void) {} ;
62                          virtual                 ~Object(){};                          virtual                 ~Object(){};
63                            Object():Parent(0){}
64                          virtual std::string name()=0;                          const std::string& name() const { return Name; }
65                            void    name(const std::string&nn) {Name=nn;}
66                                    
67                            virtual void parent(Object*o)
68                            {
69                                    Parent = o;
70                            }
71                            virtual Object* parent() const
72                            {
73                                    return Parent;
74                            }
75                  };                  };
76    
77    

Legend:
Removed from v.1.6  
changed lines
  Added in v.1.7

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26