Differences From Artifact [25865c5918]:
- File
src/OFJSONRepresentation.h
— part of check-in
[eaa612ad50]
at
2014-02-08 09:26:40
on branch trunk
— Add -[JSONRepresentationWithOptions:]
This also adds OF_JSON_REPRESENTATION_PRETTY. (user: js, size: 1660) [annotate] [blame] [check-ins using]
To Artifact [f9fd77253b]:
- File src/OFJSONRepresentation.h — part of check-in [e07fa89b44] at 2014-02-08 18:04:30 on branch trunk — Add JSON5 output option (user: js, size: 1803) [annotate] [blame] [check-ins using]
︙ | ︙ | |||
13 14 15 16 17 18 19 | * LICENSE.GPLv2 or LICENSE.GPLv3 respectively included in the packaging of this * file. */ @class OFString; enum { | | > > | 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 | * LICENSE.GPLv2 or LICENSE.GPLv3 respectively included in the packaging of this * file. */ @class OFString; enum { OF_JSON_REPRESENTATION_PRETTY = 0x01, OF_JSON_REPRESENTATION_JSON5 = 0x02, OF_JSON_REPRESENTATION_IDENTIFIER = 0x10 }; /*! * @brief A protocol implemented by classes that support encoding to a JSON * representation. * * @warning Although this method can be called directly on classes other than |
︙ | ︙ | |||
40 41 42 43 44 45 46 47 48 49 50 51 | * @brief Returns the JSON representation of the object as a string. * * @param options The options to use when creating a JSON representation.@n * Possible values are: * Value | Description * --------------------------------|------------------------- * `OF_JSON_REPRESENTATION_PRETTY` | Optimize for readability * * @return The JSON representation of the object as a string */ - (OFString*)JSONRepresentationWithOptions: (int)options; @end | > | 42 43 44 45 46 47 48 49 50 51 52 53 54 | * @brief Returns the JSON representation of the object as a string. * * @param options The options to use when creating a JSON representation.@n * Possible values are: * Value | Description * --------------------------------|------------------------- * `OF_JSON_REPRESENTATION_PRETTY` | Optimize for readability * `OF_JSON_REPRESENTATION_JSON5` | Generate JSON5 * * @return The JSON representation of the object as a string */ - (OFString*)JSONRepresentationWithOptions: (int)options; @end |