Zen API

- Home
- Topics
- Types
- Files

All Classes Files Functions Variables Typedefs Friends Macros Modules Pages
kSerializer.h
Go to the documentation of this file.
1
10 #ifndef K_API_SERIALIZER_H
11 #define K_API_SERIALIZER_H
12
13 #include <kApi/kApiDef.h>
14
15 kBeginHeader()
16
17
138 //typedef kObject kSerializer; --forward-declared in kApiDef.x.h
139
140
154 kFx(kStatus) kSerializer_Construct(kSerializer* serializer, kStream stream, kType serializerType, kAlloc allocator);
155
166 kFx(kStatus) kSerializer_LoadObject(kObject* object, kType serializerType, const kChar* filePath, kAlloc readAlloc);
167
177 kFx(kStatus) kSerializer_SaveObject(kObject object, kType serializerType, const kChar* filePath);
178
192 kFx(kStatus) kSerializer_SetVersion(kSerializer serializer, kAssembly assembly, kVersion version);
193
205 kFx(kStatus) kSerializer_SetSizeEncoding(kSerializer serializer, k32u byteCount);
206
214 kFx(k32u) kSerializer_SizeEncoding(kSerializer serializer);
215
227 kFx(kStatus) kSerializer_SetEndianness(kSerializer serializer, kEndianness endianness);
228
236 kFx(kEndianness) kSerializer_Endianness(kSerializer serializer);
237
246 kFx(kStatus) kSerializer_WriteObject(kSerializer serializer, kObject object);
247
257 kFx(kStatus) kSerializer_ReadObject(kSerializer serializer, kObject* object, kAlloc allocator);
258
267 kFx(kStatus) kSerializer_WriteText(kSerializer serializer, const kChar* data);
268
278 kFx(kStatus) kSerializer_ReadText(kSerializer serializer, kChar* data, kSize capacity);
279
288 kFx(kStatus) kSerializer_WriteByte(kSerializer serializer, kByte data);
289
299 kFx(kStatus) kSerializer_WriteByteArray(kSerializer serializer, const kByte* data, kSize count);
300
309 kFx(kStatus) kSerializer_ReadByte(kSerializer serializer, kByte* data);
310
320 kFx(kStatus) kSerializer_ReadByteArray(kSerializer serializer, kByte* data, kSize count);
321
330 kFx(kStatus) kSerializer_WriteChar(kSerializer serializer, kChar data);
331
341 kFx(kStatus) kSerializer_WriteCharArray(kSerializer serializer, const kChar* data, kSize count);
342
351 kFx(kStatus) kSerializer_ReadChar(kSerializer serializer, kChar* data);
352
362 kFx(kStatus) kSerializer_ReadCharArray(kSerializer serializer, kChar* data, kSize count);
363
372 kFx(kStatus) kSerializer_Write8u(kSerializer serializer, k8u data);
373
383 kFx(kStatus) kSerializer_Write8uArray(kSerializer serializer, const k8u* data, kSize count);
384
393 kFx(kStatus) kSerializer_Read8u(kSerializer serializer, k8u* data);
394
404 kFx(kStatus) kSerializer_Read8uArray(kSerializer serializer, k8u* data, kSize count);
405
414 kFx(kStatus) kSerializer_Write8s(kSerializer serializer, k8s data);
415
425 kFx(kStatus) kSerializer_Write8sArray(kSerializer serializer, const k8s* data, kSize count);
426
435 kFx(kStatus) kSerializer_Read8s(kSerializer serializer, k8s* data);
436
446 kFx(kStatus) kSerializer_Read8sArray(kSerializer serializer, k8s* data, kSize count);
447
456 kFx(kStatus) kSerializer_Write16u(kSerializer serializer, k16u data);
457
467 kFx(kStatus) kSerializer_Write16uArray(kSerializer serializer, const k16u* data, kSize count);
468
477 kFx(kStatus) kSerializer_Read16u(kSerializer serializer, k16u* data);
478
488 kFx(kStatus) kSerializer_Read16uArray(kSerializer serializer, k16u* data, kSize count);
489
498 kFx(kStatus) kSerializer_Write16s(kSerializer serializer, k16s data);
499
509 kFx(kStatus) kSerializer_Write16sArray(kSerializer serializer, const k16s* data, kSize count);
510
511
520 kFx(kStatus) kSerializer_Read16s(kSerializer serializer, k16s* data);
521
531 kFx(kStatus) kSerializer_Read16sArray(kSerializer serializer, k16s* data, kSize count);
532
533
542 kFx(kStatus) kSerializer_Write32u(kSerializer serializer, k32u data);
543
553 kFx(kStatus) kSerializer_Write32uArray(kSerializer serializer, const k32u* data, kSize count);
554
563 kFx(kStatus) kSerializer_Read32u(kSerializer serializer, k32u* data);
564
574 kFx(kStatus) kSerializer_Read32uArray(kSerializer serializer, k32u* data, kSize count);
575
584 kFx(kStatus) kSerializer_Write32s(kSerializer serializer, k32s data);
585
595 kFx(kStatus) kSerializer_Write32sArray(kSerializer serializer, const k32s* data, kSize count);
596
605 kFx(kStatus) kSerializer_Read32s(kSerializer serializer, k32s* data);
606
616 kFx(kStatus) kSerializer_Read32sArray(kSerializer serializer, k32s* data, kSize count);
617
626 kFx(kStatus) kSerializer_Write64u(kSerializer serializer, k64u data);
627
637 kFx(kStatus) kSerializer_Write64uArray(kSerializer serializer, const k64u* data, kSize count);
638
647 kFx(kStatus) kSerializer_Read64u(kSerializer serializer, k64u* data);
648
658 kFx(kStatus) kSerializer_Read64uArray(kSerializer serializer, k64u* data, kSize count);
659
668 kFx(kStatus) kSerializer_Write64s(kSerializer serializer, k64s data);
669
679 kFx(kStatus) kSerializer_Write64sArray(kSerializer serializer, const k64s* data, kSize count);
680
689 kFx(kStatus) kSerializer_Read64s(kSerializer serializer, k64s* data);
690
700 kFx(kStatus) kSerializer_Read64sArray(kSerializer serializer, k64s* data, kSize count);
701
710 kFx(kStatus) kSerializer_Write32f(kSerializer serializer, k32f data);
711
721 kFx(kStatus) kSerializer_Write32fArray(kSerializer serializer, const k32f* data, kSize count);
722
731 kFx(kStatus) kSerializer_Read32f(kSerializer serializer, k32f* data);
732
742 kFx(kStatus) kSerializer_Read32fArray(kSerializer serializer, k32f* data, kSize count);
743
752 kFx(kStatus) kSerializer_Write64f(kSerializer serializer, k64f data);
753
763 kFx(kStatus) kSerializer_Write64fArray(kSerializer serializer, const k64f* data, kSize count);
764
773 kFx(kStatus) kSerializer_Read64f(kSerializer serializer, k64f* data);
774
784 kFx(kStatus) kSerializer_Read64fArray(kSerializer serializer, k64f* data, kSize count);
785
797 kFx(kStatus) kSerializer_WriteSize(kSerializer serializer, kSize data);
798
811 kFx(kStatus) kSerializer_WriteSizeArray(kSerializer serializer, const kSize* data, kSize count);
812
824 kFx(kStatus) kSerializer_ReadSize(kSerializer serializer, kSize* data);
825
838 kFx(kStatus) kSerializer_ReadSizeArray(kSerializer serializer, kSize* data, kSize count);
839
851 kFx(kStatus) kSerializer_WriteSSize(kSerializer serializer, kSSize data);
852
865 kFx(kStatus) kSerializer_WriteSSizeArray(kSerializer serializer, const kSSize* data, kSize count);
866
878 kFx(kStatus) kSerializer_ReadSSize(kSerializer serializer, kSSize* data);
879
892 kFx(kStatus) kSerializer_ReadSSizeArray(kSerializer serializer, kSSize* data, kSize count);
893
907 kFx(kBool) kSerializer_IsMemoryCompatible(kSerializer serializer, kType type);
908
917 kFx(kBool) kSerializer_CanWriteType(kSerializer serializer, kType type);
918
928 kFx(kStatus) kSerializer_WriteType(kSerializer serializer, kType type, kTypeVersion* version);
929
939 kFx(kStatus) kSerializer_ReadType(kSerializer serializer, kType* type, kTypeVersion* version);
940
952 kFx(kStatus) kSerializer_WriteItems(kSerializer serializer, kType type, kTypeVersion version, const void* items, kSize count);
953
965 kFx(kStatus) kSerializer_ReadItems(kSerializer serializer, kType type, kTypeVersion version, void* items, kSize count);
966
977 kFx(kStatus) kSerializer_BeginWrite(kSerializer serializer, kType sizeType, kBool includeSize);
978
986 kFx(kStatus) kSerializer_EndWrite(kSerializer serializer);
987
997 kFx(kStatus) kSerializer_BeginRead(kSerializer serializer, kType sizeType, kBool includeSize);
998
1006 kFx(kStatus) kSerializer_EndRead(kSerializer serializer);
1007
1015 kFx(kBool) kSerializer_ReadCompleted(kSerializer serializer);
1016
1025 kFx(kStatus) kSerializer_AdvanceRead(kSerializer serializer, kSize offset);
1026
1039 kFx(kStatus) kSerializer_Flush(kSerializer serializer);
1040
1048 kFx(kStatus) kSerializer_Reset(kSerializer serializer);
1049
1057 kFx(kStream) kSerializer_Stream(kSerializer serializer);
1058
1061 #define kSerializer_WriteObject_(S, D) kxSerializer_WriteObject_(S, D)
1062 #define kSerializer_ReadObject_(S, D, A) kxSerializer_ReadObject_(S, D, A)
1063
1064 #define kSerializer_WriteByte_(S, D) kxSerializer_WriteByte_(S, D)
1065 #define kSerializer_WriteByteArray_(S, D, C) kxSerializer_WriteByteArray_(S, D, C)
1066 #define kSerializer_ReadByte_(S, D) kxSerializer_ReadByte_(S, D)
1067 #define kSerializer_ReadByteArray_(S, D, C) kxSerializer_ReadByteArray_(S, D, C)
1068
1069 #define kSerializer_WriteChar_(S, D) kxSerializer_WriteChar_(S, D)
1070 #define kSerializer_WriteCharArray_(S, D, C) kxSerializer_WriteCharArray_(S, D, C)
1071 #define kSerializer_ReadChar_(S, D) kxSerializer_ReadChar_(S, D)
1072 #define kSerializer_ReadCharArray_(S, D, C) kxSerializer_ReadCharArray_(S, D, C)
1073
1074 #define kSerializer_Write8u_(S, D) kxSerializer_Write8u_(S, D)
1075 #define kSerializer_Write8uArray_(S, D, C) kxSerializer_Write8uArray_(S, D, C)
1076 #define kSerializer_Read8u_(S, D) kxSerializer_Read8u_(S, D)
1077 #define kSerializer_Read8uArray_(S, D, C) kxSerializer_Read8uArray_(S, D, C)
1078
1079 #define kSerializer_Write8s_(S, D) kxSerializer_Write8s_(S, D)
1080 #define kSerializer_Write8sArray_(S, D, C) kxSerializer_Write8sArray_(S, D, C)
1081 #define kSerializer_Read8s_(S, D) kxSerializer_Read8s_(S, D)
1082 #define kSerializer_Read8sArray_(S, D, C) kxSerializer_Read8sArray_(S, D, C)
1083
1084 #define kSerializer_Write16u_(S, D) kxSerializer_Write16u_(S, D)
1085 #define kSerializer_Write16uArray_(S, D, C) kxSerializer_Write16uArray_(S, D, C)
1086 #define kSerializer_Read16u_(S, D) kxSerializer_Read16u_(S, D)
1087 #define kSerializer_Read16uArray_(S, D, C) kxSerializer_Read16uArray_(S, D, C)
1088
1089 #define kSerializer_Write16s_(S, D) kxSerializer_Write16s_(S, D)
1090 #define kSerializer_Write16sArray_(S, D, C) kxSerializer_Write16sArray_(S, D, C)
1091 #define kSerializer_Read16s_(S, D) kxSerializer_Read16s_(S, D)
1092 #define kSerializer_Read16sArray_(S, D, C) kxSerializer_Read16sArray_(S, D, C)
1093
1094 #define kSerializer_Write32u_(S, D) kxSerializer_Write32u_(S, D)
1095 #define kSerializer_Write32uArray_(S, D, C) kxSerializer_Write32uArray_(S, D, C)
1096 #define kSerializer_Read32u_(S, D) kxSerializer_Read32u_(S, D)
1097 #define kSerializer_Read32uArray_(S, D, C) kxSerializer_Read32uArray_(S, D, C)
1098
1099 #define kSerializer_Write32s_(S, D) kxSerializer_Write32s_(S, D)
1100 #define kSerializer_Write32sArray_(S, D, C) kxSerializer_Write32sArray_(S, D, C)
1101 #define kSerializer_Read32s_(S, D) kxSerializer_Read32s_(S, D)
1102 #define kSerializer_Read32sArray_(S, D, C) kxSerializer_Read32sArray_(S, D, C)
1103
1104 #define kSerializer_Write64u_(S, D) kxSerializer_Write64u_(S, D)
1105 #define kSerializer_Write64uArray_(S, D, C) kxSerializer_Write64uArray_(S, D, C)
1106 #define kSerializer_Read64u_(S, D) kxSerializer_Read64u_(S, D)
1107 #define kSerializer_Read64uArray_(S, D, C) kxSerializer_Read64uArray_(S, D, C)
1108
1109 #define kSerializer_Write64s_(S, D) kxSerializer_Write64s_(S, D)
1110 #define kSerializer_Write64sArray_(S, D, C) kxSerializer_Write64sArray_(S, D, C)
1111 #define kSerializer_Read64s_(S, D) kxSerializer_Read64s_(S, D)
1112 #define kSerializer_Read64sArray_(S, D, C) kxSerializer_Read64sArray_(S, D, C)
1113
1114 #define kSerializer_Write32f_(S, D) kxSerializer_Write32f_(S, D)
1115 #define kSerializer_Write32fArray_(S, D, C) kxSerializer_Write32fArray_(S, D, C)
1116 #define kSerializer_Read32f_(S, D) kxSerializer_Read32f_(S, D)
1117 #define kSerializer_Read32fArray_(S, D, C) kxSerializer_Read32fArray_(S, D, C)
1118
1119 #define kSerializer_Write64f_(S, D) kxSerializer_Write64f_(S, D)
1120 #define kSerializer_Write64fArray_(S, D, C) kxSerializer_Write64fArray_(S, D, C)
1121 #define kSerializer_Read64f_(S, D) kxSerializer_Read64f_(S, D)
1122 #define kSerializer_Read64fArray_(S, D, C) kxSerializer_Read64fArray_(S, D, C)
1123
1124 #define kSerializer_WriteSize_(S, D) kxSerializer_WriteSize_(S, D)
1125 #define kSerializer_WriteSizeArray_(S, D, C) kxSerializer_WriteSizeArray_(S, D, C)
1126 #define kSerializer_ReadSize_(S, D) kxSerializer_ReadSize_(S, D)
1127 #define kSerializer_ReadSizeArray_(S, D, C) kxSerializer_ReadSizeArray_(S, D, C)
1128
1129 #define kSerializer_WriteSSize_(S, D) kxSerializer_WriteSSize_(S, D)
1130 #define kSerializer_WriteSSizeArray_(S, D, C) kxSerializer_WriteSSizeArray_(S, D, C)
1131 #define kSerializer_ReadSSize_(S, D) kxSerializer_ReadSSize_(S, D)
1132 #define kSerializer_ReadSSizeArray_(S, D, C) kxSerializer_ReadSSizeArray_(S, D, C)
1133
1134 #define kSerializer_CanWriteType_(S, T) kxSerializer_CanWriteType_(S, T)
1135 #define kSerializer_WriteType_(S, T, V) kxSerializer_WriteType_(S, T, V)
1136 #define kSerializer_ReadType_(S, T, V) kxSerializer_ReadType_(S, T, V)
1137
1138 #define kSerializer_WriteItems_(S, T, V, I, C) kxSerializer_WriteItems_(S, T, V, I, C)
1139 #define kSerializer_ReadItems_(S, T, V, I, C) kxSerializer_ReadItems_(S, T, V, I, C)
1140
1141 #define kSerializer_BeginWrite_(S, T, I) kxSerializer_BeginWrite_(S, T, I)
1142 #define kSerializer_EndWrite_(S) kxSerializer_EndWrite_(S)
1143 #define kSerializer_BeginRead_(S, T, I) kxSerializer_BeginRead_(S, T, I)
1144 #define kSerializer_EndRead_(S) kxSerializer_EndRead_(S)
1145 #define kSerializer_ReadCompleted_(S) kxSerializer_ReadCompleted_(S)
1146
1147 #define kSerializer_AdvanceRead_(S, O) kxSerializer_AdvanceRead_(S, O)
1148 #define kSerializer_Flush_(S) kxSerializer_Flush_(S)
1149 #define kSerializer_Reset_(S) kxSerializer_Reset_(S)
1150 #define kSerializer_Stream_(S) kxSerializer_Stream_(S)
1151 #define kSerializer_Endianness_(S) kxSerializer_Endianness_(S)
1152 #define kSerializer_SizeEncoding_(S) kxSerializer_SizeEncoding_(S)
1153
1154
1156 kEndHeader()
1157
1158 #include <kApi/Io/kSerializer.x.h>
1159
1160 #endif
kSerializer::kSerializer_Write16s
kStatus kSerializer_Write16s(kSerializer serializer, k16s data)
Writes a k16s value.
kSerializer::kSerializer_ReadSizeArray
kStatus kSerializer_ReadSizeArray(kSerializer serializer, kSize *data, kSize count)
Reads a kSize array.
kSerializer::kSerializer_ReadCharArray
kStatus kSerializer_ReadCharArray(kSerializer serializer, kChar *data, kSize count)
Reads a kChar array.
k32u
Represents a 32-bit unsigned integer.
kSerializer::kSerializer_Write32sArray
kStatus kSerializer_Write32sArray(kSerializer serializer, const k32s *data, kSize count)
Writes a k32s array.
kSerializer::kSerializer_EndWrite
kStatus kSerializer_EndWrite(kSerializer serializer)
Ends writing a measured data section.
kSerializer::kSerializer_Read64u
kStatus kSerializer_Read64u(kSerializer serializer, k64u *data)
Reads a k64u value.
kSerializer::kSerializer_Write8u
kStatus kSerializer_Write8u(kSerializer serializer, k8u data)
Writes a k8u value.
kSerializer::kSerializer_ReadChar
kStatus kSerializer_ReadChar(kSerializer serializer, kChar *data)
Reads a kChar value.
kSerializer::kSerializer_Read32f
kStatus kSerializer_Read32f(kSerializer serializer, k32f *data)
Reads a k32f value.
kSerializer::kSerializer_Write16sArray
kStatus kSerializer_Write16sArray(kSerializer serializer, const k16s *data, kSize count)
Writes a k16s array.
kSerializer::kSerializer_Read8u
kStatus kSerializer_Read8u(kSerializer serializer, k8u *data)
Reads a k8u value.
k64u
Represents a 64-bit unsigned integer.
kSerializer::kSerializer_Read8s
kStatus kSerializer_Read8s(kSerializer serializer, k8s *data)
Reads a k8s value.
kSerializer::kSerializer_WriteCharArray
kStatus kSerializer_WriteCharArray(kSerializer serializer, const kChar *data, kSize count)
Writes a kChar array.
kSerializer::kSerializer_Read16s
kStatus kSerializer_Read16s(kSerializer serializer, k16s *data)
Reads a k16s value.
kSerializer::kSerializer_Write8uArray
kStatus kSerializer_Write8uArray(kSerializer serializer, const k8u *data, kSize count)
Writes a k8u array.
kSerializer::kSerializer_EndRead
kStatus kSerializer_EndRead(kSerializer serializer)
Ends reading a measured data section.
kSerializer::kSerializer_Write32uArray
kStatus kSerializer_Write32uArray(kSerializer serializer, const k32u *data, kSize count)
Writes a k32u array.
kAssembly
Represents a library of types.
kSerializer::kSerializer_Read64f
kStatus kSerializer_Read64f(kSerializer serializer, k64f *data)
Reads a k64f value.
kSerializer::kSerializer_SetVersion
kStatus kSerializer_SetVersion(kSerializer serializer, kAssembly assembly, kVersion version)
Sets the version to use when serializing types.
kSerializer::kSerializer_Write32f
kStatus kSerializer_Write32f(kSerializer serializer, k32f data)
Writes a k32f value.
kSerializer::kSerializer_Read16u
kStatus kSerializer_Read16u(kSerializer serializer, k16u *data)
Reads a k16u value.
kSerializer::kSerializer_WriteType
kStatus kSerializer_WriteType(kSerializer serializer, kType type, kTypeVersion *version)
Writes a type code.
k16u
Represents a 16-bit unsigned integer.
kSerializer::kSerializer_Write16u
kStatus kSerializer_Write16u(kSerializer serializer, k16u data)
Writes a k16u value.
kSize
Represents an unsigned integer that can store a pointer address.
kAlloc
Abstract base class for memory allocator types.
kSerializer::kSerializer_IsMemoryCompatible
kBool kSerializer_IsMemoryCompatible(kSerializer serializer, kType type)
Determines whether a value type is memory-compatible with the serializer.
kSerializer::kSerializer_Write64f
kStatus kSerializer_Write64f(kSerializer serializer, k64f data)
Writes a k64f value.
kSerializer::kSerializer_Stream
kStream kSerializer_Stream(kSerializer serializer)
Gets the underlying stream.
kSerializer::kSerializer_Read64uArray
kStatus kSerializer_Read64uArray(kSerializer serializer, k64u *data, kSize count)
Reads a k64u array.
kSerializer::kSerializer_Write64u
kStatus kSerializer_Write64u(kSerializer serializer, k64u data)
Writes a k64u value.
k8u
Represents an 8-bit unsigned integer.
kSerializer::kSerializer_ReadObject
kStatus kSerializer_ReadObject(kSerializer serializer, kObject *object, kAlloc allocator)
Reads an object from the underlying stream.
kSerializer::kSerializer_SaveObject
kStatus kSerializer_SaveObject(kObject object, kType serializerType, const kChar *filePath)
Saves an object to file using the specified serializer type.
kChar
Represents a single unit (byte) in a UTF-8 character.
kSerializer::kSerializer_Write64sArray
kStatus kSerializer_Write64sArray(kSerializer serializer, const k64s *data, kSize count)
Writes a k64s array.
kSerializer::kSerializer_SetEndianness
kStatus kSerializer_SetEndianness(kSerializer serializer, kEndianness endianness)
Explicitly sets the endianness (byte ordering) of encoded/decoded values.
kSerializer::kSerializer_Write64fArray
kStatus kSerializer_Write64fArray(kSerializer serializer, const k64f *data, kSize count)
Writes a k64f array.
kSerializer::kSerializer_WriteSize
kStatus kSerializer_WriteSize(kSerializer serializer, kSize data)
Writes a kSize value.
kByte
Represents a byte on the current platform.
kSerializer::kSerializer_WriteByte
kStatus kSerializer_WriteByte(kSerializer serializer, kByte data)
Writes a kByte value.
kSerializer::kSerializer_SizeEncoding
k32u kSerializer_SizeEncoding(kSerializer serializer)
Reports the number of bytes used to encode/decode kSize and kSSize values.
kSerializer::kSerializer_WriteSSizeArray
kStatus kSerializer_WriteSSizeArray(kSerializer serializer, const kSSize *data, kSize count)
Writes a kSSize array.
kSerializer::kSerializer_AdvanceRead
kStatus kSerializer_AdvanceRead(kSerializer serializer, kSize offset)
Reads and discards a specified number of bytes.
kSSize
Represents a signed integer that can store a pointer address.
kSerializer::kSerializer_Read32u
kStatus kSerializer_Read32u(kSerializer serializer, k32u *data)
Reads a k32u value.
kSerializer::kSerializer_WriteItems
kStatus kSerializer_WriteItems(kSerializer serializer, kType type, kTypeVersion version, const void *items, kSize count)
Writes an array of values or objects.
kSerializer::kSerializer_Write8s
kStatus kSerializer_Write8s(kSerializer serializer, k8s data)
Writes a k8s value.
kSerializer::kSerializer_Read8sArray
kStatus kSerializer_Read8sArray(kSerializer serializer, k8s *data, kSize count)
Reads a k8s array.
kSerializer::kSerializer_ReadByte
kStatus kSerializer_ReadByte(kSerializer serializer, kByte *data)
Reads a kByte value.
kSerializer
Base class for serialization/deserialization classes.
kSerializer::kSerializer_Reset
kStatus kSerializer_Reset(kSerializer serializer)
Discards any streaming context accumulated by the serializer.
kSerializer::kSerializer_WriteChar
kStatus kSerializer_WriteChar(kSerializer serializer, kChar data)
Writes a kChar value.
kSerializer::kSerializer_Read32uArray
kStatus kSerializer_Read32uArray(kSerializer serializer, k32u *data, kSize count)
Reads a k32u array.
kSerializer::kSerializer_CanWriteType
kBool kSerializer_CanWriteType(kSerializer serializer, kType type)
Determines whether this serializer can write the specified object type.
kSerializer::kSerializer_Read32s
kStatus kSerializer_Read32s(kSerializer serializer, k32s *data)
Reads a k32s value.
kSerializer::kSerializer_Write32u
kStatus kSerializer_Write32u(kSerializer serializer, k32u data)
Writes a k32u value.
kSerializer::kSerializer_BeginWrite
kStatus kSerializer_BeginWrite(kSerializer serializer, kType sizeType, kBool includeSize)
Begins writing a measured section of data, using an 8, 16, 32, or 64-bit integer to record the size...
kSerializer::kSerializer_Read64sArray
kStatus kSerializer_Read64sArray(kSerializer serializer, k64s *data, kSize count)
Reads a k64s array.
kSerializer::kSerializer_Write32s
kStatus kSerializer_Write32s(kSerializer serializer, k32s data)
Writes a k32s value.
kType::kTypeVersion
kPointer kTypeVersion
Represents an opaque reference to type version information (used in object serialization).
kSerializer::kSerializer_BeginRead
kStatus kSerializer_BeginRead(kSerializer serializer, kType sizeType, kBool includeSize)
Begins reading a measured data section.
kSerializer::kSerializer_Write64s
kStatus kSerializer_Write64s(kSerializer serializer, k64s data)
Writes a k64s value.
kApiDef.h
Core Zen type declarations.
kSerializer::kSerializer_Read64fArray
kStatus kSerializer_Read64fArray(kSerializer serializer, k64f *data, kSize count)
Reads a k64f array.
kSerializer::kSerializer_ReadItems
kStatus kSerializer_ReadItems(kSerializer serializer, kType type, kTypeVersion version, void *items, kSize count)
Reads an array of values or objects.
kStream
Represents an I/O stream.
kSerializer::kSerializer_ReadSize
kStatus kSerializer_ReadSize(kSerializer serializer, kSize *data)
Reads a kSize value.
k32s
Represents a 32-bit signed integer.
kSerializer::kSerializer_Write16uArray
kStatus kSerializer_Write16uArray(kSerializer serializer, const k16u *data, kSize count)
Writes a k16u array.
kSerializer::kSerializer_LoadObject
kStatus kSerializer_LoadObject(kObject *object, kType serializerType, const kChar *filePath, kAlloc readAlloc)
Loads an object from file using the specified serializer type.
kSerializer::kSerializer_Construct
kStatus kSerializer_Construct(kSerializer *serializer, kStream stream, kType serializerType, kAlloc allocator)
Constructs a serializer object using the specified serialization format.
kSerializer::kSerializer_Write8sArray
kStatus kSerializer_Write8sArray(kSerializer serializer, const k8s *data, kSize count)
Writes a k8s array.
kSerializer::kSerializer_Read64s
kStatus kSerializer_Read64s(kSerializer serializer, k64s *data)
Reads a k64s value.
kSerializer::kSerializer_Read16sArray
kStatus kSerializer_Read16sArray(kSerializer serializer, k16s *data, kSize count)
Reads a k16s array.
kSerializer::kSerializer_WriteSizeArray
kStatus kSerializer_WriteSizeArray(kSerializer serializer, const kSize *data, kSize count)
Writes a kSize array.
k64s
Represents a 64-bit signed integer.
kSerializer::kSerializer_ReadText
kStatus kSerializer_ReadText(kSerializer serializer, kChar *data, kSize capacity)
Reads a null-terminated kChar array.
kSerializer::kSerializer_WriteText
kStatus kSerializer_WriteText(kSerializer serializer, const kChar *data)
Writes a null-terminated kChar array.
kSerializer::kSerializer_WriteByteArray
kStatus kSerializer_WriteByteArray(kSerializer serializer, const kByte *data, kSize count)
Writes a kByte array.
k8s
Represents an 8-bit signed integer.
kEndianness
Represents the byte-ordering of primative data types.
kSerializer::kSerializer_ReadByteArray
kStatus kSerializer_ReadByteArray(kSerializer serializer, kByte *data, kSize count)
Reads a kByte array.
kSerializer::kSerializer_Read32sArray
kStatus kSerializer_Read32sArray(kSerializer serializer, k32s *data, kSize count)
Reads a k32s array.
kType
Represents metadata about a type (class, interface, or value).
kSerializer::kSerializer_SetSizeEncoding
kStatus kSerializer_SetSizeEncoding(kSerializer serializer, k32u byteCount)
Explicitly sets the number of bytes used to encode/decode kSize and kSSize values.
kSerializer::kSerializer_WriteObject
kStatus kSerializer_WriteObject(kSerializer serializer, kObject object)
Writes an object to the underlying stream.
kSerializer::kSerializer_ReadCompleted
kBool kSerializer_ReadCompleted(kSerializer serializer)
Determines whether the current measured read section has more bytes.
kSerializer::kSerializer_Write32fArray
kStatus kSerializer_Write32fArray(kSerializer serializer, const k32f *data, kSize count)
Writes a k32f array.
k16s
Represents a 16-bit signed integer.
k32f
Represents a 32-bit floating-point number.
kObject
Root of all Zen classes.
kVersion
Represents a version number.
kSerializer::kSerializer_Read16uArray
kStatus kSerializer_Read16uArray(kSerializer serializer, k16u *data, kSize count)
Reads a k16u array.
kStatus
Represents an error code.
kSerializer::kSerializer_ReadSSize
kStatus kSerializer_ReadSSize(kSerializer serializer, kSSize *data)
Reads a kSSize value.
kSerializer::kSerializer_ReadType
kStatus kSerializer_ReadType(kSerializer serializer, kType *type, kTypeVersion *version)
Reads a type code.
kSerializer::kSerializer_Read8uArray
kStatus kSerializer_Read8uArray(kSerializer serializer, k8u *data, kSize count)
Reads a k8u array.
kSerializer::kSerializer_Write64uArray
kStatus kSerializer_Write64uArray(kSerializer serializer, const k64u *data, kSize count)
Writes a k64u array.
kSerializer::kSerializer_ReadSSizeArray
kStatus kSerializer_ReadSSizeArray(kSerializer serializer, kSSize *data, kSize count)
Reads a kSSize array.
k64f
Represents a 64-bit floating-point number.
kSerializer::kSerializer_Read32fArray
kStatus kSerializer_Read32fArray(kSerializer serializer, k32f *data, kSize count)
Reads a k32f array.
kBool
Represents a boolean value.
kSerializer::kSerializer_WriteSSize
kStatus kSerializer_WriteSSize(kSerializer serializer, kSSize data)
Writes a kSSize value.
kSerializer::kSerializer_Endianness
kEndianness kSerializer_Endianness(kSerializer serializer)
Reports the (byte ordering) of encoded/decoded values.
kSerializer::kSerializer_Flush
kStatus kSerializer_Flush(kSerializer serializer)
Flushes the serializer write buffer to the underlying stream.