![]() |
CotC C# SDK for Unity
v1.4.0.1
Making social games is easy !
|
Represents a key/value system, also known as virtual file system. This class is scoped by domain, meaning that you can call .Domain("yourdomain") and perform additional calls that are scoped.
Public Member Functions | |
GamerVfs | Domain (string domain) |
Sets the domain affected by this object. You should typically use it this way: gamer.GamerVfs.Domain("private").SetKey(...); More... | |
Promise< Bundle > | GetKey (string key) |
Retrieves an individual key from the key/value system. More... | |
Promise< Bundle > | GetValue (string key=null) |
Retrieves an individual key or all keys from the key/value system. More... | |
Promise< byte[]> | GetKeyBinary (string key) |
Retrieves the binary data of an individual key from the key/value system. More... | |
Promise< byte[]> | GetBinary (string key) |
Retrieves the binary data of an individual key from the key/value system. More... | |
Promise< Done > | SetKey (string key, Bundle value) |
Sets the value of a key in the key/value system. More... | |
Promise< Done > | SetValue (string key, Bundle value) |
Sets the value of a single key or all keys in the key/value system. More... | |
Promise< Done > | SetKeyBinary (string key, byte[] binaryData) |
Sets the value of a key in the key/value system as binary data. More... | |
Promise< Done > | SetBinary (string key, byte[] binaryData) |
Sets the value of a key in the key/value system as binary data. More... | |
Promise< Done > | RemoveKey (string key) |
Removes a single key from the key/value system. More... | |
Promise< Done > | DeleteValue (string key=null) |
Removes a single key or all keys from the key/value system. More... | |
Removes a single key or all keys from the key/value system.
key | The name of the key to remove. Beware, if you don't pass any key at all, then ALL the key/value will be removed. Should be used with care! |
GamerVfs CotcSdk.GamerVfs.Domain | ( | string | domain | ) |
Sets the domain affected by this object. You should typically use it this way: gamer.GamerVfs.Domain("private").SetKey(...);
domain | Domain on which to scope the VFS. Defaults to private if not specified. |
Promise<byte[]> CotcSdk.GamerVfs.GetBinary | ( | string | key | ) |
Retrieves the binary data of an individual key from the key/value system.
key | The name of the key to be fetched. |
Retrieves an individual key from the key/value system.
key | The name of the key to be fetched. |
This method is obsolete, use GetValue instead.
Promise<byte[]> CotcSdk.GamerVfs.GetKeyBinary | ( | string | key | ) |
Retrieves the binary data of an individual key from the key/value system.
key | The name of the key to be fetched. |
This method is obsolete, use GetBinary instead.
Retrieves an individual key or all keys from the key/value system.
key | The name of the key to be fetched. If you don't pass any key, then all the keys will be returned in a global JSON |
Removes a single key from the key/value system.
key | The name of the key to remove. |
This method is obsolete, use DeleteValue instead.
Sets the value of a key in the key/value system as binary data.
key | The name of the key to set the value for. |
binaryData | The value to set as binary data. |
Sets the value of a key in the key/value system.
key | The name of the key to set the value for. |
value | The value to set. As usual with bundles, casting is implicitly done, so you may as well call this method passing an integer or string as value for instance. |
This method is obsolete, use SetValue instead.
Sets the value of a key in the key/value system as binary data.
key | The name of the key to set the value for. |
binaryData | The value to set as binary data. |
This method is obsolete, use SetBinary instead.
Sets the value of a single key or all keys in the key/value system.
key | The name of the key to set the value for. |
value | The value to set. As usual with bundles, casting is implicitly done, so you may as well call this method passing an integer or string as value for instance. |