diff options
Diffstat (limited to '')
-rw-r--r-- | libraries/irrlicht-1.8/include/IAttributeExchangingObject.h | 142 |
1 files changed, 71 insertions, 71 deletions
diff --git a/libraries/irrlicht-1.8/include/IAttributeExchangingObject.h b/libraries/irrlicht-1.8/include/IAttributeExchangingObject.h index 5b13cdb..9c64b7d 100644 --- a/libraries/irrlicht-1.8/include/IAttributeExchangingObject.h +++ b/libraries/irrlicht-1.8/include/IAttributeExchangingObject.h | |||
@@ -1,71 +1,71 @@ | |||
1 | // Copyright (C) 2002-2012 Nikolaus Gebhardt | 1 | // Copyright (C) 2002-2012 Nikolaus Gebhardt |
2 | // This file is part of the "Irrlicht Engine". | 2 | // This file is part of the "Irrlicht Engine". |
3 | // For conditions of distribution and use, see copyright notice in irrlicht.h | 3 | // For conditions of distribution and use, see copyright notice in irrlicht.h |
4 | 4 | ||
5 | #ifndef __I_ATTRIBUTE_EXCHANGING_OBJECT_H_INCLUDED__ | 5 | #ifndef __I_ATTRIBUTE_EXCHANGING_OBJECT_H_INCLUDED__ |
6 | #define __I_ATTRIBUTE_EXCHANGING_OBJECT_H_INCLUDED__ | 6 | #define __I_ATTRIBUTE_EXCHANGING_OBJECT_H_INCLUDED__ |
7 | 7 | ||
8 | #include "IReferenceCounted.h" | 8 | #include "IReferenceCounted.h" |
9 | 9 | ||
10 | 10 | ||
11 | namespace irr | 11 | namespace irr |
12 | { | 12 | { |
13 | 13 | ||
14 | namespace io | 14 | namespace io |
15 | { | 15 | { |
16 | 16 | ||
17 | class IAttributes; | 17 | class IAttributes; |
18 | 18 | ||
19 | //! Enumeration flags passed through SAttributeReadWriteOptions to the IAttributeExchangingObject object | 19 | //! Enumeration flags passed through SAttributeReadWriteOptions to the IAttributeExchangingObject object |
20 | enum E_ATTRIBUTE_READ_WRITE_FLAGS | 20 | enum E_ATTRIBUTE_READ_WRITE_FLAGS |
21 | { | 21 | { |
22 | //! Serialization/Deserializion is done for an xml file | 22 | //! Serialization/Deserializion is done for an xml file |
23 | EARWF_FOR_FILE = 0x00000001, | 23 | EARWF_FOR_FILE = 0x00000001, |
24 | 24 | ||
25 | //! Serialization/Deserializion is done for an editor property box | 25 | //! Serialization/Deserializion is done for an editor property box |
26 | EARWF_FOR_EDITOR = 0x00000002, | 26 | EARWF_FOR_EDITOR = 0x00000002, |
27 | 27 | ||
28 | //! When writing filenames, relative paths should be used | 28 | //! When writing filenames, relative paths should be used |
29 | EARWF_USE_RELATIVE_PATHS = 0x00000004 | 29 | EARWF_USE_RELATIVE_PATHS = 0x00000004 |
30 | }; | 30 | }; |
31 | 31 | ||
32 | 32 | ||
33 | //! struct holding data describing options | 33 | //! struct holding data describing options |
34 | struct SAttributeReadWriteOptions | 34 | struct SAttributeReadWriteOptions |
35 | { | 35 | { |
36 | //! Constructor | 36 | //! Constructor |
37 | SAttributeReadWriteOptions() | 37 | SAttributeReadWriteOptions() |
38 | : Flags(0), Filename(0) | 38 | : Flags(0), Filename(0) |
39 | { | 39 | { |
40 | } | 40 | } |
41 | 41 | ||
42 | //! Combination of E_ATTRIBUTE_READ_WRITE_FLAGS or other, custom ones | 42 | //! Combination of E_ATTRIBUTE_READ_WRITE_FLAGS or other, custom ones |
43 | s32 Flags; | 43 | s32 Flags; |
44 | 44 | ||
45 | //! Optional filename | 45 | //! Optional filename |
46 | const fschar_t* Filename; | 46 | const fschar_t* Filename; |
47 | }; | 47 | }; |
48 | 48 | ||
49 | 49 | ||
50 | //! An object which is able to serialize and deserialize its attributes into an attributes object | 50 | //! An object which is able to serialize and deserialize its attributes into an attributes object |
51 | class IAttributeExchangingObject : virtual public IReferenceCounted | 51 | class IAttributeExchangingObject : virtual public IReferenceCounted |
52 | { | 52 | { |
53 | public: | 53 | public: |
54 | 54 | ||
55 | //! Writes attributes of the object. | 55 | //! Writes attributes of the object. |
56 | /** Implement this to expose the attributes of your scene node animator for | 56 | /** Implement this to expose the attributes of your scene node animator for |
57 | scripting languages, editors, debuggers or xml serialization purposes. */ | 57 | scripting languages, editors, debuggers or xml serialization purposes. */ |
58 | virtual void serializeAttributes(io::IAttributes* out, io::SAttributeReadWriteOptions* options=0) const {} | 58 | virtual void serializeAttributes(io::IAttributes* out, io::SAttributeReadWriteOptions* options=0) const {} |
59 | 59 | ||
60 | //! Reads attributes of the object. | 60 | //! Reads attributes of the object. |
61 | /** Implement this to set the attributes of your scene node animator for | 61 | /** Implement this to set the attributes of your scene node animator for |
62 | scripting languages, editors, debuggers or xml deserialization purposes. */ | 62 | scripting languages, editors, debuggers or xml deserialization purposes. */ |
63 | virtual void deserializeAttributes(io::IAttributes* in, io::SAttributeReadWriteOptions* options=0) {} | 63 | virtual void deserializeAttributes(io::IAttributes* in, io::SAttributeReadWriteOptions* options=0) {} |
64 | 64 | ||
65 | }; | 65 | }; |
66 | 66 | ||
67 | } // end namespace io | 67 | } // end namespace io |
68 | } // end namespace irr | 68 | } // end namespace irr |
69 | 69 | ||
70 | #endif | 70 | #endif |
71 | 71 | ||