Panda3D
 All Classes Functions Variables Enumerations
factoryParam.h
1 // Filename: factoryParam.h
2 // Created by: drose (08May00)
3 //
4 ////////////////////////////////////////////////////////////////////
5 //
6 // PANDA 3D SOFTWARE
7 // Copyright (c) Carnegie Mellon University. All rights reserved.
8 //
9 // All use of this software is subject to the terms of the revised BSD
10 // license. You should have received a copy of this license along
11 // with this source code in a file named "LICENSE."
12 //
13 ////////////////////////////////////////////////////////////////////
14 
15 #ifndef FACTORYPARAM_H
16 #define FACTORYPARAM_H
17 
18 #include "pandabase.h"
19 
20 #include "typedReferenceCount.h"
21 
22 #include "pvector.h"
23 
24 ////////////////////////////////////////////////////////////////////
25 // Class : FactoryParam
26 // Description : The base class of any number of specific pieces of
27 // parameter information that might be passed to a
28 // Factory's CreateFunc to control what kind of instance
29 // is created. This class is empty and contains no
30 // data, but different kinds of factories may expect
31 // parameters of various types that derive from
32 // FactoryParam (and do contain data).
33 ////////////////////////////////////////////////////////////////////
34 class EXPCL_PANDA_PUTIL FactoryParam : public TypedReferenceCount {
35 public:
36  INLINE FactoryParam();
37  INLINE FactoryParam(const FactoryParam &other);
38  INLINE void operator = (const FactoryParam &other);
39  INLINE ~FactoryParam();
40 
41 public:
42  virtual TypeHandle get_type() const {
43  return get_class_type();
44  }
45  virtual TypeHandle force_init_type() {init_type(); return get_class_type();}
46  static TypeHandle get_class_type() {
47  return _type_handle;
48  }
49  static void init_type() {
50  TypedReferenceCount::init_type();
51  register_type(_type_handle, "FactoryParam",
52  TypedReferenceCount::get_class_type());
53  }
54 
55 private:
56  static TypeHandle _type_handle;
57 };
58 
59 #include "factoryParam.I"
60 
61 #endif
62 
The base class of any number of specific pieces of parameter information that might be passed to a Fa...
Definition: factoryParam.h:34
A base class for things which need to inherit from both TypedObject and from ReferenceCount.
TypeHandle is the identifier used to differentiate C++ class types.
Definition: typeHandle.h:85