Watson Developer Cloud Unity SDK
1.0.0
The Unity SDK uses the Watson Developer Cloud services, a collection of REST APIs and SDKs that use cognitive computing to solve complex problems.
|
Public Member Functions | |
delegate void | OnGetToken (AuthenticationToken authenticationToken, string data) |
The OnGetToken callback. More... | |
Static Public Member Functions | |
static Type[] | FindAllDerivedTypes (Type type) |
This helper functions returns all Type's that inherit from the given type. More... | |
static bool | Approximately (double a, double b, double tolerance=0.0001) |
Approximately the specified a, b and tolerance. More... | |
static bool | Approximately (float a, float b, float tolerance=0.0001f) |
Approximately the specified a, b and tolerance. More... | |
static bool | Approximately (Vector3 a, Vector3 b, float tolerance=0.0001f) |
Approximately the specified a, b and tolerance. More... | |
static bool | Approximately (Quaternion a, Quaternion b, float tolerance=0.0001f) |
Approximately Quaternion with the specified a, b and tolerance. More... | |
static GameObject | FindObject (GameObject parent, string nameChild) |
Finds the object in child of parent object by name of child More... | |
static T[] | FindObjects< T > (GameObject parent, string nameChild, bool isContains=false, bool sortByName=false, bool includeInactive=true) |
Finds the objects in children of parent object by name of child More... | |
static string | GetMD5 (string s) |
Get the MD5 hash of a string. More... | |
static string | RemoveTags (string s, char tagStartChar= '<', char tagEndChar= '>') |
Removes any tags from a string. (e.g. <title></title>) More... | |
static string | GetOnOffString (bool b) |
Gets the on off string. More... | |
static string | StripString (string s) |
Strips the prepending ! statment from string. More... | |
static double | GetEpochUTCMilliseconds () |
Gets the EPOCH time in UTC time zome More... | |
static double | GetEpochUTCSeconds () |
Gets the epoch UTC seconds. More... | |
static DateTime | GetLocalDateTimeFromEpoch (double epochTime) |
Gets the date time from epoch. More... | |
static byte[] | Color32ArrayToByteArray (Color32[] colors) |
Converts Color32 array to Byte array. More... | |
static T | DeserializeResponse< T > (byte[] resp, object obj=null) |
Deserializes the response. More... | |
static T | DeserializeResponse< T > (string json, object obj=null) |
Deserializes the response. More... | |
static string | AddTopLevelObjectToJson (string json, string objectName) |
Hack to add a top level object to a json string because Unity does not like top level collections. More... | |
static string | GetMimeType (string extension) |
static string | GetExtension (string mimeType) |
static bool | GetToken (OnGetToken callback, string serviceEndpoint, string username, string password, string tokenName="") |
Gets a token to authenticate serivce calls instead of using username and password. More... | |
Properties | |
static string | MacAddress [get] |
Returns First valid Mac address of the local machine More... | |
Utility functions.
|
inlinestatic |
Hack to add a top level object to a json string because Unity does not like top level collections.
json | The json string. |
objectName | The name of the top level object. |
|
inlinestatic |
Approximately the specified a, b and tolerance.
a | The first component. |
b | The second component. |
tolerance | Tolerance. |
|
inlinestatic |
Approximately the specified a, b and tolerance.
a | The first component. |
b | The second component. |
tolerance | Tolerance. |
|
inlinestatic |
Approximately the specified a, b and tolerance.
a | The first component. |
b | The second component. |
tolerance | Tolerance. |
|
inlinestatic |
Approximately Quaternion with the specified a, b and tolerance.
a | The first component. |
b | The second component. |
tolerance | Tolerance. |
|
inlinestatic |
Converts Color32 array to Byte array.
colors | Color32 array of the image. |
|
inlinestatic |
Deserializes the response.
resp | Resp. |
obj | Object. |
T | The 1st type parameter. |
T | : | class | |
T | : | new() |
|
inlinestatic |
Deserializes the response.
json | Json string of object |
obj | Object. |
T | The 1st type parameter. |
T | : | class | |
T | : | new() |
|
inlinestatic |
This helper functions returns all Type's that inherit from the given type.
type | The Type to find all types that inherit from the given type. |
|
inlinestatic |
Finds the object in child of parent object by name of child
parent | Parent Object. |
nameChild | Name child. |
|
inlinestatic |
Finds the objects in children of parent object by name of child
parent | Parent. |
nameChild | Name child. |
isContains | Check string contains the name instead of equality. |
sortByName | If true, children will be returned sorted by their name. |
T | : | Component |
|
inlinestatic |
Gets the EPOCH time in UTC time zome
|
inlinestatic |
Gets the epoch UTC seconds.
|
inlinestatic |
|
inlinestatic |
Gets the date time from epoch.
epochTime | Epoch time. |
kind | Kind. |
|
inlinestatic |
Get the MD5 hash of a string.
s |
|
inlinestatic |
|
inlinestatic |
Gets the on off string.
b | If set to true b. |
|
inlinestatic |
Gets a token to authenticate serivce calls instead of using username and password.
callback | The OnGetToken callback, |
serviceEndpoint | The service endpoint. |
username | The service username. |
password | The service password. |
tokenName | A user defined name for the token. |
delegate void IBM.Watson.DeveloperCloud.Utilities.Utility.OnGetToken | ( | AuthenticationToken | authenticationToken, |
string | data | ||
) |
The OnGetToken callback.
authenticationToken | The authentication token object. |
data | User defined custom data. |
|
inlinestatic |
Removes any tags from a string. (e.g. <title></title>)
s |
|
inlinestatic |
Strips the prepending ! statment from string.
s | S. |
|
staticget |
Returns First valid Mac address of the local machine