Class JSONReaderClass

Namespace
ESRI.ArcGIS.esriSystem
Assembly
ESRI.Server.System.dll
[Guid("B4578901-05DE-4BDA-AAEB-849EC52102B1")]
[ClassInterface(ClassInterfaceType.None)]
public class JSONReaderClass : JSONReader, IJSONReader2, IJSONReader, ISupportErrorInfo
Inheritance
JSONReaderClass
Implements
Inherited Members

Constructors

JSONReaderClass()

public JSONReaderClass()

Explicit Interface Implementations

CurrentTokenType

Obtains type of current token.

virtual JSONTokenType CurrentTokenType { get; }

Returns

JSONTokenType

FindProperties(IStringArray)

Reads current object until one of property names matches. Case is ignored. Return value is an index of property name that matched, otherwise -1.

virtual int FindProperties(IStringArray propnames)

Parameters

propnames IStringArray

Returns

int

FindProperty(string)

Reads current object until property name matches or object ends. Case is ignored.

virtual bool FindProperty(string propname)

Parameters

propname string

Returns

bool

IJSONReader2_CurrentTokenType

virtual JSONTokenType IJSONReader2_CurrentTokenType { get; }

Returns

JSONTokenType

IJSONReader2_FindProperties(IStringArray)

virtual int IJSONReader2_FindProperties(IStringArray propnames)

Parameters

propnames IStringArray

Returns

int

IJSONReader2_FindProperty(string)

virtual bool IJSONReader2_FindProperty(string propname)

Parameters

propname string

Returns

bool

IJSONReader2_IsBoolean()

virtual bool IJSONReader2_IsBoolean()

Returns

bool

IJSONReader2_IsEndOfArray()

virtual bool IJSONReader2_IsEndOfArray()

Returns

bool

IJSONReader2_IsEndOfObject()

virtual bool IJSONReader2_IsEndOfObject()

Returns

bool

IJSONReader2_IsNull()

virtual bool IJSONReader2_IsNull()

Returns

bool

IJSONReader2_IsNumber()

virtual bool IJSONReader2_IsNumber()

Returns

bool

IJSONReader2_IsStartOfArray()

virtual bool IJSONReader2_IsStartOfArray()

Returns

bool

IJSONReader2_IsStartOfObject()

virtual bool IJSONReader2_IsStartOfObject()

Returns

bool

IJSONReader2_IsString()

virtual bool IJSONReader2_IsString()

Returns

bool

IJSONReader2_Read()

virtual void IJSONReader2_Read()

IJSONReader2_ReadFrom(IStream)

virtual void IJSONReader2_ReadFrom(IStream inputStream)

Parameters

inputStream IStream

IJSONReader2_ReadFromString(string)

virtual void IJSONReader2_ReadFromString(string Text)

Parameters

Text string

IJSONReader2_ReadPropertyName()

virtual string IJSONReader2_ReadPropertyName()

Returns

string

IJSONReader2_ReadValue()

virtual object IJSONReader2_ReadValue()

Returns

object

IJSONReader2_ReadValueAsBoolean()

virtual bool IJSONReader2_ReadValueAsBoolean()

Returns

bool

IJSONReader2_ReadValueAsDate()

virtual DateTime IJSONReader2_ReadValueAsDate()

Returns

DateTime

IJSONReader2_ReadValueAsDouble()

virtual double IJSONReader2_ReadValueAsDouble()

Returns

double

IJSONReader2_ReadValueAsLong()

virtual int IJSONReader2_ReadValueAsLong()

Returns

int

IJSONReader2_ReadValueAsString()

virtual string IJSONReader2_ReadValueAsString()

Returns

string

IJSONReader2_SkipUntilArrayEnds()

virtual void IJSONReader2_SkipUntilArrayEnds()

IJSONReader2_SkipUntilObjectEnds()

virtual void IJSONReader2_SkipUntilObjectEnds()

IJSONReader2_Stream

virtual IStream IJSONReader2_Stream { get; }

Returns

IStream

InterfaceSupportsErrorInfo(ref Guid)

virtual void InterfaceSupportsErrorInfo(ref Guid riid)

Parameters

riid Guid

IsBoolean()

Indicates true if current token is a property value or array value of boolean type.

virtual bool IsBoolean()

Returns

bool

IsEndOfArray()

Indicates true if current token is ']'.

virtual bool IsEndOfArray()

Returns

bool

IsEndOfObject()

Indicates true if current token is '}'.

virtual bool IsEndOfObject()

Returns

bool

IsNull()

Indicates true if current token is a property value or array value and equals to null.

virtual bool IsNull()

Returns

bool

IsNumber()

Indicates true if current token is a property value or array value of numeric type.

virtual bool IsNumber()

Returns

bool

IsStartOfArray()

Indicates true if current token is '['.

virtual bool IsStartOfArray()

Returns

bool

IsStartOfObject()

Indicates true if current token is '{'.

virtual bool IsStartOfObject()

Returns

bool

IsString()

Indicates true if current token is a property value or array value of type string.

virtual bool IsString()

Returns

bool

ParseJSONString(string)

Parses JSON string into memory. Returns either IJSONObject or IJSONArray in a 'root' parameter. Doesn't change state of existing IJSONReader2 instance.

virtual object ParseJSONString(string json)

Parameters

json string

Returns

object

Read()

Reads next JSON token.

virtual void Read()

ReadFrom(IStream)

Specifies input stream.

virtual void ReadFrom(IStream inputStream)

Parameters

inputStream IStream

ReadFromString(string)

Specifies input as string.

virtual void ReadFromString(string Text)

Parameters

Text string

ReadPropertyName()

Obtains property name. Advances to the next token.

virtual string ReadPropertyName()

Returns

string

ReadValue()

Obtains array or property value as Variant. Advances to the next token.

virtual object ReadValue()

Returns

object

ReadValueAsBoolean()

Obtains array or property value as boolean. Advances to the next token. If property value cannot be coerced to boolean, returns E_FAIL.

virtual bool ReadValueAsBoolean()

Returns

bool

ReadValueAsDate()

Obtains property or array value as date. Advances to the next token. If property value cannot be coerced to datetime, returns E_FAIL.

virtual DateTime ReadValueAsDate()

Returns

DateTime

ReadValueAsDouble()

Obtains property or array value as number. Advances to the next token. If property value cannot be coerced to double, returns E_FAIL.

virtual double ReadValueAsDouble()

Returns

double

ReadValueAsLong()

Obtains property or array value as number. Advances to the next token. If property value cannot be coerced to long, returns E_FAIL.

virtual int ReadValueAsLong()

Returns

int

ReadValueAsString()

Obtains property or array value as string. Advances to the next token. If property value cannot be coerced to string, returns E_FAIL.

virtual string ReadValueAsString()

Returns

string

ReadValueEx(out object, out int)

Obtains array or property value as Variant along with precision if it is a double. Advances to the next token.

virtual void ReadValueEx(out object pVal, out int precision)

Parameters

pVal object
precision int

RemoveAllBookmarks()

Removes all bookmarks.

virtual void RemoveAllBookmarks()

RemoveBookmark(string)

Moves the reader back to a token that has a bookmark with the given name.

virtual void RemoveBookmark(string Name)

Parameters

Name string

ReturnToBookmark(string)

Moves the reader back to a token that has a bookmark with the given name.

virtual void ReturnToBookmark(string Name)

Parameters

Name string

SetBookmark(string)

Creates a bookmark on the current token and assigns it a name. Only works if you use ReadFromString(), otherwise returns E_FAIL.

virtual void SetBookmark(string Name)

Parameters

Name string

SkipUntilArrayEnds()

Skips the rest of the current object, including closing bracket.

virtual void SkipUntilArrayEnds()

SkipUntilObjectEnds()

Skips the rest of the current object, including closing bracket.

virtual void SkipUntilObjectEnds()

Stream

Obtains underlying stream.

virtual IStream Stream { get; }

Returns

IStream