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
218 kFx(kStatus) kSerializer_SetEndianness(kSerializer serializer, kEndianness endianness);
219
228 kFx(kStatus) kSerializer_WriteObject(kSerializer serializer, kObject object);
229
239 kFx(kStatus) kSerializer_ReadObject(kSerializer serializer, kObject* object, kAlloc allocator);
240
249 kFx(kStatus) kSerializer_WriteText(kSerializer serializer, const kChar* data);
250
260 kFx(kStatus) kSerializer_ReadText(kSerializer serializer, kChar* data, kSize capacity);
261
270 kFx(kStatus) kSerializer_WriteByte(kSerializer serializer, kByte data);
271
281 kFx(kStatus) kSerializer_WriteByteArray(kSerializer serializer, const kByte* data, kSize count);
282
291 kFx(kStatus) kSerializer_ReadByte(kSerializer serializer, kByte* data);
292
302 kFx(kStatus) kSerializer_ReadByteArray(kSerializer serializer, kByte* data, kSize count);
303
312 kFx(kStatus) kSerializer_WriteChar(kSerializer serializer, kChar data);
313
323 kFx(kStatus) kSerializer_WriteCharArray(kSerializer serializer, const kChar* data, kSize count);
324
333 kFx(kStatus) kSerializer_ReadChar(kSerializer serializer, kChar* data);
334
344 kFx(kStatus) kSerializer_ReadCharArray(kSerializer serializer, kChar* data, kSize count);
345
354 kFx(kStatus) kSerializer_Write8u(kSerializer serializer, k8u data);
355
365 kFx(kStatus) kSerializer_Write8uArray(kSerializer serializer, const k8u* data, kSize count);
366
375 kFx(kStatus) kSerializer_Read8u(kSerializer serializer, k8u* data);
376
386 kFx(kStatus) kSerializer_Read8uArray(kSerializer serializer, k8u* data, kSize count);
387
396 kFx(kStatus) kSerializer_Write8s(kSerializer serializer, k8s data);
397
407 kFx(kStatus) kSerializer_Write8sArray(kSerializer serializer, const k8s* data, kSize count);
408
417 kFx(kStatus) kSerializer_Read8s(kSerializer serializer, k8s* data);
418
428 kFx(kStatus) kSerializer_Read8sArray(kSerializer serializer, k8s* data, kSize count);
429
438 kFx(kStatus) kSerializer_Write16u(kSerializer serializer, k16u data);
439
449 kFx(kStatus) kSerializer_Write16uArray(kSerializer serializer, const k16u* data, kSize count);
450
459 kFx(kStatus) kSerializer_Read16u(kSerializer serializer, k16u* data);
460
470 kFx(kStatus) kSerializer_Read16uArray(kSerializer serializer, k16u* data, kSize count);
471
480 kFx(kStatus) kSerializer_Write16s(kSerializer serializer, k16s data);
481
491 kFx(kStatus) kSerializer_Write16sArray(kSerializer serializer, const k16s* data, kSize count);
492
493
502 kFx(kStatus) kSerializer_Read16s(kSerializer serializer, k16s* data);
503
513 kFx(kStatus) kSerializer_Read16sArray(kSerializer serializer, k16s* data, kSize count);
514
515
524 kFx(kStatus) kSerializer_Write32u(kSerializer serializer, k32u data);
525
535 kFx(kStatus) kSerializer_Write32uArray(kSerializer serializer, const k32u* data, kSize count);
536
545 kFx(kStatus) kSerializer_Read32u(kSerializer serializer, k32u* data);
546
556 kFx(kStatus) kSerializer_Read32uArray(kSerializer serializer, k32u* data, kSize count);
557
566 kFx(kStatus) kSerializer_Write32s(kSerializer serializer, k32s data);
567
577 kFx(kStatus) kSerializer_Write32sArray(kSerializer serializer, const k32s* data, kSize count);
578
587 kFx(kStatus) kSerializer_Read32s(kSerializer serializer, k32s* data);
588
598 kFx(kStatus) kSerializer_Read32sArray(kSerializer serializer, k32s* data, kSize count);
599
608 kFx(kStatus) kSerializer_Write64u(kSerializer serializer, k64u data);
609
619 kFx(kStatus) kSerializer_Write64uArray(kSerializer serializer, const k64u* data, kSize count);
620
629 kFx(kStatus) kSerializer_Read64u(kSerializer serializer, k64u* data);
630
640 kFx(kStatus) kSerializer_Read64uArray(kSerializer serializer, k64u* data, kSize count);
641
650 kFx(kStatus) kSerializer_Write64s(kSerializer serializer, k64s data);
651
661 kFx(kStatus) kSerializer_Write64sArray(kSerializer serializer, const k64s* data, kSize count);
662
671 kFx(kStatus) kSerializer_Read64s(kSerializer serializer, k64s* data);
672
682 kFx(kStatus) kSerializer_Read64sArray(kSerializer serializer, k64s* data, kSize count);
683
692 kFx(kStatus) kSerializer_Write32f(kSerializer serializer, k32f data);
693
703 kFx(kStatus) kSerializer_Write32fArray(kSerializer serializer, const k32f* data, kSize count);
704
713 kFx(kStatus) kSerializer_Read32f(kSerializer serializer, k32f* data);
714
724 kFx(kStatus) kSerializer_Read32fArray(kSerializer serializer, k32f* data, kSize count);
725
734 kFx(kStatus) kSerializer_Write64f(kSerializer serializer, k64f data);
735
745 kFx(kStatus) kSerializer_Write64fArray(kSerializer serializer, const k64f* data, kSize count);
746
755 kFx(kStatus) kSerializer_Read64f(kSerializer serializer, k64f* data);
756
766 kFx(kStatus) kSerializer_Read64fArray(kSerializer serializer, k64f* data, kSize count);
767
779 kFx(kStatus) kSerializer_WriteSize(kSerializer serializer, kSize data);
780
793 kFx(kStatus) kSerializer_WriteSizeArray(kSerializer serializer, const kSize* data, kSize count);
794
806 kFx(kStatus) kSerializer_ReadSize(kSerializer serializer, kSize* data);
807
820 kFx(kStatus) kSerializer_ReadSizeArray(kSerializer serializer, kSize* data, kSize count);
821
833 kFx(kStatus) kSerializer_WriteSSize(kSerializer serializer, kSSize data);
834
847 kFx(kStatus) kSerializer_WriteSSizeArray(kSerializer serializer, const kSSize* data, kSize count);
848
860 kFx(kStatus) kSerializer_ReadSSize(kSerializer serializer, kSSize* data);
861
874 kFx(kStatus) kSerializer_ReadSSizeArray(kSerializer serializer, kSSize* data, kSize count);
875
885 kFx(kStatus) kSerializer_WriteType(kSerializer serializer, kType type, kTypeVersion* version);
886
896 kFx(kStatus) kSerializer_ReadType(kSerializer serializer, kType* type, kTypeVersion* version);
897
909 kFx(kStatus) kSerializer_WriteItems(kSerializer serializer, kType type, kTypeVersion version, const void* items, kSize count);
910
922 kFx(kStatus) kSerializer_ReadItems(kSerializer serializer, kType type, kTypeVersion version, void* items, kSize count);
923
934 kFx(kStatus) kSerializer_BeginWrite(kSerializer serializer, kType sizeType, kBool includeSize);
935
943 kFx(kStatus) kSerializer_EndWrite(kSerializer serializer);
944
954 kFx(kStatus) kSerializer_BeginRead(kSerializer serializer, kType sizeType, kBool includeSize);
955
963 kFx(kStatus) kSerializer_EndRead(kSerializer serializer);
964
972 kFx(kBool) kSerializer_ReadCompleted(kSerializer serializer);
973
982 kFx(kStatus) kSerializer_AdvanceRead(kSerializer serializer, kSize offset);
983
996 kFx(kStatus) kSerializer_Flush(kSerializer serializer);
997
1005 kFx(kStatus) kSerializer_Reset(kSerializer serializer);
1006
1014 kFx(kStream) kSerializer_Stream(kSerializer serializer);
1015
1018 #define kSerializer_WriteObject_(S, D) kxSerializer_WriteObject_(S, D)
1019 #define kSerializer_ReadObject_(S, D, A) kxSerializer_ReadObject_(S, D, A)
1020
1021 #define kSerializer_WriteByte_(S, D) kxSerializer_WriteByte_(S, D)
1022 #define kSerializer_WriteByteArray_(S, D, C) kxSerializer_WriteByteArray_(S, D, C)
1023 #define kSerializer_ReadByte_(S, D) kxSerializer_ReadByte_(S, D)
1024 #define kSerializer_ReadByteArray_(S, D, C) kxSerializer_ReadByteArray_(S, D, C)
1025
1026 #define kSerializer_WriteChar_(S, D) kxSerializer_WriteChar_(S, D)
1027 #define kSerializer_WriteCharArray_(S, D, C) kxSerializer_WriteCharArray_(S, D, C)
1028 #define kSerializer_ReadChar_(S, D) kxSerializer_ReadChar_(S, D)
1029 #define kSerializer_ReadCharArray_(S, D, C) kxSerializer_ReadCharArray_(S, D, C)
1030
1031 #define kSerializer_Write8u_(S, D) kxSerializer_Write8u_(S, D)
1032 #define kSerializer_Write8uArray_(S, D, C) kxSerializer_Write8uArray_(S, D, C)
1033 #define kSerializer_Read8u_(S, D) kxSerializer_Read8u_(S, D)
1034 #define kSerializer_Read8uArray_(S, D, C) kxSerializer_Read8uArray_(S, D, C)
1035
1036 #define kSerializer_Write8s_(S, D) kxSerializer_Write8s_(S, D)
1037 #define kSerializer_Write8sArray_(S, D, C) kxSerializer_Write8sArray_(S, D, C)
1038 #define kSerializer_Read8s_(S, D) kxSerializer_Read8s_(S, D)
1039 #define kSerializer_Read8sArray_(S, D, C) kxSerializer_Read8sArray_(S, D, C)
1040
1041 #define kSerializer_Write16u_(S, D) kxSerializer_Write16u_(S, D)
1042 #define kSerializer_Write16uArray_(S, D, C) kxSerializer_Write16uArray_(S, D, C)
1043 #define kSerializer_Read16u_(S, D) kxSerializer_Read16u_(S, D)
1044 #define kSerializer_Read16uArray_(S, D, C) kxSerializer_Read16uArray_(S, D, C)
1045
1046 #define kSerializer_Write16s_(S, D) kxSerializer_Write16s_(S, D)
1047 #define kSerializer_Write16sArray_(S, D, C) kxSerializer_Write16sArray_(S, D, C)
1048 #define kSerializer_Read16s_(S, D) kxSerializer_Read16s_(S, D)
1049 #define kSerializer_Read16sArray_(S, D, C) kxSerializer_Read16sArray_(S, D, C)
1050
1051 #define kSerializer_Write32u_(S, D) kxSerializer_Write32u_(S, D)
1052 #define kSerializer_Write32uArray_(S, D, C) kxSerializer_Write32uArray_(S, D, C)
1053 #define kSerializer_Read32u_(S, D) kxSerializer_Read32u_(S, D)
1054 #define kSerializer_Read32uArray_(S, D, C) kxSerializer_Read32uArray_(S, D, C)
1055
1056 #define kSerializer_Write32s_(S, D) kxSerializer_Write32s_(S, D)
1057 #define kSerializer_Write32sArray_(S, D, C) kxSerializer_Write32sArray_(S, D, C)
1058 #define kSerializer_Read32s_(S, D) kxSerializer_Read32s_(S, D)
1059 #define kSerializer_Read32sArray_(S, D, C) kxSerializer_Read32sArray_(S, D, C)
1060
1061 #define kSerializer_Write64u_(S, D) kxSerializer_Write64u_(S, D)
1062 #define kSerializer_Write64uArray_(S, D, C) kxSerializer_Write64uArray_(S, D, C)
1063 #define kSerializer_Read64u_(S, D) kxSerializer_Read64u_(S, D)
1064 #define kSerializer_Read64uArray_(S, D, C) kxSerializer_Read64uArray_(S, D, C)
1065
1066 #define kSerializer_Write64s_(S, D) kxSerializer_Write64s_(S, D)
1067 #define kSerializer_Write64sArray_(S, D, C) kxSerializer_Write64sArray_(S, D, C)
1068 #define kSerializer_Read64s_(S, D) kxSerializer_Read64s_(S, D)
1069 #define kSerializer_Read64sArray_(S, D, C) kxSerializer_Read64sArray_(S, D, C)
1070
1071 #define kSerializer_Write32f_(S, D) kxSerializer_Write32f_(S, D)
1072 #define kSerializer_Write32fArray_(S, D, C) kxSerializer_Write32fArray_(S, D, C)
1073 #define kSerializer_Read32f_(S, D) kxSerializer_Read32f_(S, D)
1074 #define kSerializer_Read32fArray_(S, D, C) kxSerializer_Read32fArray_(S, D, C)
1075
1076 #define kSerializer_Write64f_(S, D) kxSerializer_Write64f_(S, D)
1077 #define kSerializer_Write64fArray_(S, D, C) kxSerializer_Write64fArray_(S, D, C)
1078 #define kSerializer_Read64f_(S, D) kxSerializer_Read64f_(S, D)
1079 #define kSerializer_Read64fArray_(S, D, C) kxSerializer_Read64fArray_(S, D, C)
1080
1081 #define kSerializer_WriteSize_(S, D) kxSerializer_WriteSize_(S, D)
1082 #define kSerializer_WriteSizeArray_(S, D, C) kxSerializer_WriteSizeArray_(S, D, C)
1083 #define kSerializer_ReadSize_(S, D) kxSerializer_ReadSize_(S, D)
1084 #define kSerializer_ReadSizeArray_(S, D, C) kxSerializer_ReadSizeArray_(S, D, C)
1085
1086 #define kSerializer_WriteSSize_(S, D) kxSerializer_WriteSSize_(S, D)
1087 #define kSerializer_WriteSSizeArray_(S, D, C) kxSerializer_WriteSSizeArray_(S, D, C)
1088 #define kSerializer_ReadSSize_(S, D) kxSerializer_ReadSSize_(S, D)
1089 #define kSerializer_ReadSSizeArray_(S, D, C) kxSerializer_ReadSSizeArray_(S, D, C)
1090
1091 #define kSerializer_WriteType_(S, T, V) kxSerializer_WriteType_(S, T, V)
1092 #define kSerializer_ReadType_(S, T, V) kxSerializer_ReadType_(S, T, V)
1093
1094 #define kSerializer_WriteItems_(S, T, V, I, C) kxSerializer_WriteItems_(S, T, V, I, C)
1095 #define kSerializer_ReadItems_(S, T, V, I, C) kxSerializer_ReadItems_(S, T, V, I, C)
1096
1097 #define kSerializer_BeginWrite_(S, T, I) kxSerializer_BeginWrite_(S, T, I)
1098 #define kSerializer_EndWrite_(S) kxSerializer_EndWrite_(S)
1099 #define kSerializer_BeginRead_(S, T, I) kxSerializer_BeginRead_(S, T, I)
1100 #define kSerializer_EndRead_(S) kxSerializer_EndRead_(S)
1101 #define kSerializer_ReadCompleted_(S) kxSerializer_ReadCompleted_(S)
1102
1103 #define kSerializer_AdvanceRead_(S, O) kxSerializer_AdvanceRead_(S, O)
1104 #define kSerializer_Flush_(S) kxSerializer_Flush_(S)
1105 #define kSerializer_Reset_(S) kxSerializer_Reset_(S)
1106 #define kSerializer_Stream_(S) kxSerializer_Stream_(S)
1107
1108
1110 kEndHeader()
1111
1112 #include <kApi/Io/kSerializer.x.h>
1113
1114 #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_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_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_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_Flush
kStatus kSerializer_Flush(kSerializer serializer)
Flushes the serializer write buffer to the underlying stream.