Panda3D
interrogateComponent.h
Go to the documentation of this file.
1 /**
2  * PANDA 3D SOFTWARE
3  * Copyright (c) Carnegie Mellon University. All rights reserved.
4  *
5  * All use of this software is subject to the terms of the revised BSD
6  * license. You should have received a copy of this license along
7  * with this source code in a file named "LICENSE."
8  *
9  * @file interrogateComponent.h
10  * @author drose
11  * @date 2000-08-08
12  */
13 
14 #ifndef INTERROGATECOMPONENT_H
15 #define INTERROGATECOMPONENT_H
16 
17 #include "dtoolbase.h"
18 
19 #include "interrogate_interface.h"
20 #include "interrogate_request.h"
21 
22 #include <vector>
23 
24 class IndexRemapper;
25 
26 /**
27  * The base class for things that are part of the interrogate database. This
28  * includes types, functions, and function wrappers.
29  */
30 class EXPCL_INTERROGATEDB InterrogateComponent {
31 public:
32  INLINE InterrogateComponent(InterrogateModuleDef *def = nullptr);
33  INLINE InterrogateComponent(const InterrogateComponent &copy);
34  INLINE void operator = (const InterrogateComponent &copy);
35 
36  INLINE bool has_library_name() const;
37  INLINE const char *get_library_name() const;
38 
39  INLINE bool has_module_name() const;
40  INLINE const char *get_module_name() const;
41 
42  INLINE bool has_name() const;
43  INLINE const std::string &get_name() const;
44 
45  INLINE int get_num_alt_names() const;
46  INLINE const std::string &get_alt_name(int n) const;
47 
48  void output(std::ostream &out) const;
49  void input(std::istream &in);
50 
51 protected:
52  static std::string _empty_string;
53 
54 private:
56  std::string _name;
57 
58  typedef std::vector<std::string> Strings;
59  Strings _alt_names;
60 
61  friend class InterrogateBuilder;
62  friend class FunctionRemap;
63 };
64 
65 #include "interrogateComponent.I"
66 
67 #endif
IndexRemapper
This class manages a mapping of integers to integers.
Definition: indexRemapper.h:29
InterrogateComponent
The base class for things that are part of the interrogate database.
Definition: interrogateComponent.h:30
interrogate_request.h
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
dtoolbase.h
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
interrogateComponent.I
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
interrogate_interface.h
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
InterrogateModuleDef
Definition: interrogate_request.h:52