示例#1
0
    void DebugCallback(APIService.APIError error, APIService.IResponse response)
    {
        if (null != error)
        {
            //Debug.Log(error.Message);
            return;
        }

        Dictionary <string, object> payloadData = response.Payload.Data;

        if (payloadData.ContainsKey("session_id"))
        {
            sessionID = payloadData["session_id"].ToString();
            //Debug.Log("Session ID Saved: " + sessionID);
        }

        //Debug.Log("HEADERS");
        foreach (KeyValuePair <string, string> header in response.Headers.Data)
        {
            //Debug.Log(header.Key + " : " + header.Value);
        }
        //Debug.Log("PAYLOAD DATA");
        foreach (KeyValuePair <string, object> data in response.Payload.Data)
        {
            //Debug.Log(data.Key + " : " + data.Value.ToString());
        }

        //	Debug.Log("User is Authenticated: " + apiService.IsAuthenticated);
    }
示例#2
0
    void APICallback(APIService.APIError error, APIService.IResponse response)
    {
        if (!apiService)
        {
            return;
        }
        if (null != error)
        {
            Debug.LogWarning(error.Message);
            return;
        }
        Dictionary <string, object> payloadData = response.Payload.Data;

        if (payloadData.ContainsKey("session_id"))
        {
            sessionID = payloadData["session_id"].ToString();
            //Debug.Log("Session ID Saved: " + sessionID);
        }
    }