Gocator API

- Home
- Topics
- Types
- Files

All Classes Files Functions Variables Typedefs Macros Modules Pages
GoSerializer.h
Go to the documentation of this file.
1 /**
2 * @file GoSerializer.h
3 * @brief Declares the GoSerializer class.
4 *
5 * @internal
6 * Copyright (C) 2016-2022 by LMI Technologies Inc.
7 * Licensed under the MIT License.
8 * Redistributed files must retain the above copyright notice.
9 */
10 #ifndef GO_SDK_SERIALIZER_H
11 #define GO_SDK_SERIALIZER_H
12
13 #include <GoSdk/GoSdkDef.h>
14 #include <kApi/Io/kSerializer.h>
15
16 #define GO_SERIALIZATION_FORMAT_NAME "godat" //format name, used for version info lookup
17 #define GO_SERIALIZATION_FORMAT_VERSION "6.0.0.0" //format version, used for version info lookup
18
19 // Need a level of indirection to stringify a number.
20 // Must only call GoSerializerTypeIdStr() and DO NOT call GoSerializerTypeIdStr_().
21 #define GoSerializerTypeIdStr_(TYPE_ID) #TYPE_ID
22 #define GoSerializerTypeIdStr(TYPE_ID) GoSerializerTypeIdStr_(TYPE_ID)
23
24 /**
25 * @class GoSerializer
26 * @extends kSerializer
27 * @ingroup GoSdk-Internal
28 * @brief Serializes/deserializes objects to/from Gocator Data Protocol.
29 */
30 typedef kSerializer GoSerializer;
31
32 /**
33 * Constructs a GoSerializer object.
34 *
35 * @public @memberof GoSerializer
36 * @version Introduced in firmware 4.0.10.27
37 * @param serializer Receives the constructed object.
38 * @param stream Stream for reading or writing.
39 * @param allocator Memory allocator (or kNULL for default).
40 * @return Operation status.
41 */
42 GoFx(kStatus) GoSerializer_Construct(GoSerializer* serializer, kStream stream, kAlloc allocator);
43
44 #include <GoSdk/Internal/GoSerializer.x.h>
45
46 #endif
GoSerializer::GoSerializer_Construct
kStatus GoSerializer_Construct(GoSerializer *serializer, kStream stream, kAlloc allocator)
Constructs a GoSerializer object.
GoSerializer
Serializes/deserializes objects to/from Gocator Data Protocol.
kAlloc
kSerializer
GoSdkDef.h
Essential SDK declarations.
kStream
kSerializer.h
kStatus