Panda3D
panda
src
egg
eggUserData.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 eggUserData.h
10
* @author drose
11
* @date 2003-06-03
12
*/
13
14
#ifndef EGGUSERDATA_H
15
#define EGGUSERDATA_H
16
17
#include "
pandabase.h
"
18
19
#include "
typedReferenceCount.h
"
20
21
/**
22
* This is a base class for a user-defined data type to extend egg structures
23
* in processing code. The user of the egg library may derive from
24
* EggUserData to associate any arbitrary data with various egg objects.
25
*
26
* However, this data will not be written out to the disk when the egg file is
27
* written; it is an in-memory object only.
28
*/
29
class
EXPCL_PANDA_EGG
EggUserData
:
public
TypedReferenceCount
{
30
PUBLISHED:
31
INLINE
EggUserData
();
32
INLINE
EggUserData
(
const
EggUserData
©);
33
INLINE
EggUserData
&operator = (
const
EggUserData
©);
34
35
virtual
~
EggUserData
();
36
37
public
:
38
static
TypeHandle
get_class_type() {
39
return
_type_handle;
40
}
41
static
void
init_type() {
42
TypedReferenceCount::init_type();
43
register_type
(_type_handle,
"EggUserData"
,
44
TypedReferenceCount::get_class_type());
45
}
46
virtual
TypeHandle
get_type()
const
{
47
return
get_class_type();
48
}
49
virtual
TypeHandle
force_init_type() {init_type();
return
get_class_type();}
50
51
private
:
52
static
TypeHandle
_type_handle;
53
};
54
55
#include "
eggUserData.I
"
56
57
#endif
EggUserData
This is a base class for a user-defined data type to extend egg structures in processing code.
Definition:
eggUserData.h:29
pandabase.h
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
register_type
void register_type(TypeHandle &type_handle, const std::string &name)
This inline function is just a convenient way to call TypeRegistry::register_type(),...
Definition:
register_type.I:22
TypedReferenceCount
A base class for things which need to inherit from both TypedObject and from ReferenceCount.
Definition:
typedReferenceCount.h:31
TypeHandle
TypeHandle is the identifier used to differentiate C++ class types.
Definition:
typeHandle.h:81
eggUserData.I
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
typedReferenceCount.h
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
Generated on Mon Sep 14 2020 15:06:50 for Panda3D by
1.8.20