JsonObject Members

JsonObject has the following members.

Public Constructors

  Name Description
JsonObject Initializes a new instance of a JsonObject that represents a JSON object containing a collection of name and JsonValue pairs.

Public Properties

  Name Description
Size Gets the size (count) of the collection.
ValueType Gets the type of the encapsulated JSON value. Possible types are defined by JsonValueType.

Public Methods

  Name Description
Clear Removes all items from the collection.
First Returns the iterator for iteration over the key/value pairs in the JsonObject.
GetArray Returns a JsonArray, if the ValueType of the encapsulated value is Array.
GetBoolean Gets a Boolean value, if the ValueType of the encapsulated value is Boolean.
GetNamedArray Gets the JsonArray value with the specified name.
GetNamedBoolean Gets the Boolean value with the specified name.
GetNamedNumber Gets the number value with the specified name.
GetNamedObject Gets the JsonObject value with the specified name.
GetNamedString Gets the string value with the specified name.
GetNamedValue Gets the JsonValue value with the specified name.
GetNumber Gets the number, if the ValueType of the encapsulated value is Number.
GetObject Gets the JsonObject, if the ValueType of the encapsulated value is Object.
GetString Gets the string, if the ValueType of the encapsulated value is String.
GetView Gets a JsonObject view.
HasKey Indicates whether the JsonObject has an entry with the requested key.
Insert Adds a new entry to the JsonObject.
Lookup Gets the JSON value associated with the supplied key, if an entry with that key exists.
  Parse Parses the specified JSON string that represents a JsonObject into a JSON value.
Remove Removes the JSON object associated with the specified key.
SetNamedValue Sets the value of the first JsonValue object with the specified name to the specified value. If no such object is found, a new name and JsonValue pair is inserted into the JSON object.
Stringify Retrieves the JSON representation of the encapsulated value.
  TryParse Parses the specified string that represents a JSON object into a JsonObject.

See also

Reference

JsonObject Class

Windows.Data.Json Namespace