00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015 #ifndef EGGNAMEDOBJECT_H
00016 #define EGGNAMEDOBJECT_H
00017
00018 #include "pandabase.h"
00019
00020 #include "eggObject.h"
00021 #include "namable.h"
00022 #include "referenceCount.h"
00023
00024
00025
00026
00027
00028
00029 class EXPCL_PANDAEGG EggNamedObject : public EggObject, public Namable {
00030 PUBLISHED:
00031 INLINE EggNamedObject(const string &name = "");
00032 INLINE EggNamedObject(const EggNamedObject ©);
00033 INLINE EggNamedObject &operator = (const EggNamedObject ©);
00034
00035 void output(ostream &out) const;
00036
00037 public:
00038 void write_header(ostream &out, int indent_level,
00039 const char *egg_keyword) const;
00040
00041
00042 static TypeHandle get_class_type() {
00043 return _type_handle;
00044 }
00045 static void init_type() {
00046 EggObject::init_type();
00047 Namable::init_type();
00048 register_type(_type_handle, "EggNamedObject",
00049 EggObject::get_class_type(),
00050 Namable::get_class_type());
00051 }
00052 virtual TypeHandle get_type() const {
00053 return get_class_type();
00054 }
00055 virtual TypeHandle force_init_type() {init_type(); return get_class_type();}
00056
00057 private:
00058 static TypeHandle _type_handle;
00059 };
00060
00061 INLINE ostream &operator << (ostream &out, const EggNamedObject &n);
00062
00063 #include "eggNamedObject.I"
00064
00065 #endif