Click or drag to resize
JsonObjectGetOrAddObject Method
Gets value stored under given key and casts it to object. If key does not exist new empty object is added to the specified key.

Namespace: Dextronet.Jsonie
Assembly: Dextronet.Jsonie (in Dextronet.Jsonie.dll) Version: 1.0.0.0
Syntax
public JsonObject GetOrAddObject(
	string key
)

Parameters

key
Type: SystemString
The key of the member to get.

Return Value

Type: JsonObject
The value stored under given key casted to JsonObject.
Exceptions
ExceptionCondition
ArgumentNullExceptionkey is null.
InvalidCastExceptionIf property with given key exist and is not JsonObject.
Examples
Dim myInnerObject = myObject.GetOrAddObject("inner") myInnerObject("some") = value
See Also