JubeatPlus 3.9.11
Loading...
Searching...
No Matches
CJSONSerializer.h
Go to the documentation of this file.
1
11
12#import <Foundation/Foundation.h>
13
14NS_ASSUME_NONNULL_BEGIN
15
20@protocol CJSONDataRepresentation <NSObject>
26@end
27
31@interface CJSONSerializer : NSObject
32
37@property(nonatomic) NSUInteger options;
38
44+ (instancetype)serializer;
45
53- (BOOL)isValidJSONObject:(nullable id)object;
54
62- (nullable NSData *)serializeObject:(nullable id)object error:(NSError *_Nullable *_Nullable)error;
63
71- (nullable NSData *)serializeNull:(nullable NSNull *)null
72 error:(NSError *_Nullable *_Nullable)error;
73
82- (nullable NSData *)serializeNumber:(nullable NSNumber *)number
83 error:(NSError *_Nullable *_Nullable)error;
84
92- (nullable NSData *)serializeString:(nullable NSString *)string
93 error:(NSError *_Nullable *_Nullable)error;
94
102- (nullable NSData *)serializeArray:(nullable NSArray *)array
103 error:(NSError *_Nullable *_Nullable)error;
104
112- (nullable NSData *)serializeDictionary:(nullable NSDictionary *)dictionary
113 error:(NSError *_Nullable *_Nullable)error;
114
115@end
116
117NS_ASSUME_NONNULL_END
118
119// code: language=Objective-C
120// kate: hl Objective-C;
121// vim: set ft=objc :
Turns Foundation objects into JSON data.
Definition CJSONSerializer.h:32
NSUInteger options
Serialisation options.
Definition CJSONSerializer.h:37
instancetype serializer()
Vends a fresh serialiser instance.
Definition CJSONSerializer.m:47
NSData * JSONDataRepresentation()
The receiver's own JSON encoding.