Ditto 1.1.8
Protected Member Functions | Properties | List of all members
DittoSDK.DittoDocumentIDPath Class Reference

Provides an interface to specify a path to a key in a document ID that you can then call a function on to get the value at the specified key as a specific type. More...

Inheritance diagram for DittoSDK.DittoDocumentIDPath:
DittoSDK.DocumentPath

Protected Member Functions

override CBORObject GetCborObjectAtCurrentPath ()
 
abstract CBORObject GetCborObjectAtCurrentPath ()
 

Properties

DittoDocumentIDPath this[string path] [get]
 Used to specify a path to a key in the document ID that you can subscript further to access a nested key in the document ID. More...
 
DittoDocumentIDPath this[int index] [get]
 Used to specify an index in the array at the preceding key-path specified through the subscripting defined previously. You can subscript the return value further to access a further nested key in the document ID. More...
 
- Properties inherited from DittoSDK.DocumentPath
object Value [get]
 Gets the value at the previously specified key in the document as an object if it exists, otherwise the return value will be null.
 
string String [get]
 Gets the value at the previously specified key in the document as a string if possible, otherwise the return value will be null.
 
string StringValue [get]
 Gets the value at the previously specified key in the document as a string if possible, otherwise the return value will be "" (an empty string).
 
int Int32Value [get]
 Gets the value at the previously specified key in the document as an Int32 if possible, otherwise the return value will be 0.
 
long Int64Value [get]
 Gets the value at the previously specified key in the document as an Int64 if possible, otherwise the return value will be 0.
 
uint UInt32Value [get]
 Gets the value at the previously specified key in the document as a UInt32 if possible, otherwise the return value will be 0.
 
ulong UInt64Value [get]
 Gets the value at the previously specified key in the document as a UInt64 if possible, otherwise the return value will be 0.
 
float FloatValue [get]
 Gets the value at the previously specified key in the document as a Float if possible, otherwise the return value will be 0.0.
 
double DoubleValue [get]
 Gets the value at the previously specified key in the document as a UInt32 if possible, otherwise the return value will be 0.
 
bool BooleanValue [get]
 Gets a value indicating whether the previously specified key in the document as a bool if possible, otherwise the return value will be false.
 
List< object > List [get]
 Gets the value at the previously specified key in the document as a List<object> if possible, otherwise the return value will be null.
 
List< object > ListValue [get]
 Gets the value at the previously specified key in the document as a List<object> if possible, otherwise the return value will be [] (an empty list).
 
Dictionary< string, object > Dictionary [get]
 Gets the value at the previously specified key in the document as a Dictionary<string, object> if possible, otherwise the return value will be null.
 
Dictionary< string, object > DictionaryValue [get]
 Gets the value at the previously specified key in the document as a Dictionary<string, object> if possible, otherwise the return value will be {} (an empty dictionary).
 
DittoAttachmentToken AttachmentToken [get]
 Gets the value at the previously specified key in the document as a DittoAttachmentToken if possible, otherwise the return value will be null.
 

Detailed Description

Provides an interface to specify a path to a key in a document ID that you can then call a function on to get the value at the specified key as a specific type.

You obtain a DittoDocumentIDPath by subscripting a DittoDocumentID and you can then further subscript a DittoDocumentIDPath to further specify the key of the document ID that you want to get the value of.

Member Function Documentation

◆ GetCborObjectAtCurrentPath()

override CBORObject DittoSDK.DittoDocumentIDPath.GetCborObjectAtCurrentPath ( )
inlineprotectedvirtual

Implements DittoSDK.DocumentPath.

Property Documentation

◆ this[int index]

DittoDocumentIDPath DittoSDK.DittoDocumentIDPath.this[int index]
get

Used to specify an index in the array at the preceding key-path specified through the subscripting defined previously. You can subscript the return value further to access a further nested key in the document ID.

Parameters
indexThe index of the array that you wish to access in the key previously specified with the preceding subscripting.
Returns
The same DittoDocumentIDPath object with the provided index incorporated into the document ID path.

◆ this[string path]

DittoDocumentIDPath DittoSDK.DittoDocumentIDPath.this[string path]
get

Used to specify a path to a key in the document ID that you can subscript further to access a nested key in the document ID.

Parameters
pathThe next part of the path needed to get to the key in the document ID you wish to get the value of.
Returns
The same DittoDocumentIDPath object with the provided key incorporated into the document ID path.