Turns JSON data into Foundation objects.
More...
#include <CJSONDeserializer.h>
|
| (instancetype) | + deserializer |
| | A new autoreleased deserialiser.
|
Turns JSON data into Foundation objects.
◆ deserialize:error:
| - (nullable id) deserialize: |
|
(nullable NSData *) | data |
| error: |
|
(NSError *__autoreleasing *) | outError |
Deserialises to whatever the JSON describes.
Nil and empty input are the same case, and both are reported as error -11 rather than as an empty result.
- Parameters
-
| data | The JSON text. |
| outError | Where to report a parse failure. |
- Returns
- The parsed object, or nil.
- Ghidra address:
- 0x63718
◆ deserializeAsArray:error:
| - (nullable NSArray *) deserializeAsArray: |
|
(nullable NSData *) | data |
| error: |
|
(NSError *__autoreleasing *) | outError |
Deserialises, requiring an array at the top level.
- Parameters
-
| data | The JSON text. |
| outError | Where to report a parse failure. |
- Returns
- The parsed array, or nil.
- Ghidra address:
- 0x639c8
◆ deserializeAsDictionary:error:
| - (nullable NSDictionary *) deserializeAsDictionary: |
|
(nullable NSData *) | data |
| error: |
|
(NSError *__autoreleasing *) | outError |
Deserialises, requiring a dictionary at the top level.
- Parameters
-
| data | The JSON text. |
| outError | Where to report a parse failure. |
- Returns
- The parsed dictionary, or nil.
- Ghidra address:
- 0x63870
◆ deserializer
| + (instancetype) deserializer |
|
|
|
A new autoreleased deserialiser.
- Returns
- The deserialiser.
- Ghidra address:
- 0x63504
- Ghidra address:
- 0x63504
◆ init
Builds a deserialiser.
The scanner is not created here.
- Returns
- The initialised deserialiser.
- Ghidra address:
- 0x6352c
- Ghidra address:
- 0x6352c
◆ allowedEncoding
| - (NSUInteger) allowedEncoding |
|
readwritenonatomicassign |
Which text encoding the input is allowed to be in.
Also stored on the scanner rather than here.
- Ghidra address:
- 0x63684 (getter)
- Ghidra address:
- 0x63684
◆ nullObject
What a JSON null becomes.
Stored on the scanner, not here — the property has no backing ivar in the metadata.
- Ghidra address:
- 0x635c4 (getter)
- Ghidra address:
- 0x635c4
◆ options
Deserialisation options.
Unlike the two above, this one does have its own ivar — and nothing in the class reads it.
- Ghidra address:
- 0x63b34 (getter)
◆ scanner
The scanner that does the work, built on first use.
- Ghidra address:
- 0x63564 (getter)
- Ghidra address:
- 0x63564
The documentation for this class was generated from the following files: