// Path: sdk/src/main/java/com/theeyetribe/clientsdk/GazeManager.java
// public class GazeManager extends GazeManagerCore
// {
//     private GazeManager()
//     {
//         super();
//     }
// 
//     public static GazeManager getInstance()
//     {
//         return Holder.INSTANCE;
//     }
// 
//     private static class Holder
//     {
//         // thread-safe initialization on demand
//         static final GazeManager INSTANCE = new GazeManager();
//     }
// 
//     protected GazeApiManager createApiManager(GazeApiManager.IGazeApiResponseListener responseListener, GazeApiManager.IGazeApiConnectionListener connectionListener)
//     {
//         return new GazeApiManager(responseListener, connectionListener);
//     }
// 
//     protected boolean parseApiResponse(final Response response, final Request request)
//     {
//         return false;
//     }
// }


import com.google.gson.Gson;
import com.google.gson.JsonObject;
import com.theeyetribe.clientsdk.GazeManager;
import com.theeyetribe.clientsdk.utils.HashUtils;
/*
 * Copyright (c) 2013-present, The Eye Tribe. 
 * All rights reserved.
 *
 * This source code is licensed under the BSD-style license found in the LICENSE file in the root directory of this source tree. 
 *
 */

package com.theeyetribe.clientsdk.request;


/**
 * Request is the generic base class for requests in the EyeTribe API
 *
 * @see <a href="http://dev.theeyetribe.com/api/#api">EyeTribe API - Client Message</a>
 */
public class Request<T> implements Comparable<Request<T>>
{
    public String category;
    public String request;
    public int id;

    private transient boolean mCanceled;

    public transient long timeStamp;

    public transient int retryAttempts;

    public transient Object asyncLock;

    private transient final Class<T> type;

    public Request(Class<T> type) {
        this.type = type;
    }

    public T parseJsonResponse(JsonObject response, Gson gson)
    {
// Path: sdk/src/main/java/com/theeyetribe/clientsdk/GazeManager.java
// public class GazeManager extends GazeManagerCore
// {
//     private GazeManager()
//     {
//         super();
//     }
// 
//     public static GazeManager getInstance()
//     {
//         return Holder.INSTANCE;
//     }
// 
//     private static class Holder
//     {
//         // thread-safe initialization on demand
//         static final GazeManager INSTANCE = new GazeManager();
//     }
// 
//     protected GazeApiManager createApiManager(GazeApiManager.IGazeApiResponseListener responseListener, GazeApiManager.IGazeApiConnectionListener connectionListener)
//     {
//         return new GazeApiManager(responseListener, connectionListener);
//     }
// 
//     protected boolean parseApiResponse(final Response response, final Request request)
//     {
//         return false;
//     }
// }


// Path: sdk/src/main/java/com/theeyetribe/clientsdk/request/Request.java
import com.google.gson.Gson;
import com.google.gson.JsonObject;
import com.theeyetribe.clientsdk.GazeManager;
import com.theeyetribe.clientsdk.utils.HashUtils;

/*
 * Copyright (c) 2013-present, The Eye Tribe. 
 * All rights reserved.
 *
 * This source code is licensed under the BSD-style license found in the LICENSE file in the root directory of this source tree. 
 *
 */

package com.theeyetribe.clientsdk.request;


/**
 * Request is the generic base class for requests in the EyeTribe API
 *
 * @see <a href="http://dev.theeyetribe.com/api/#api">EyeTribe API - Client Message</a>
 */
public class Request<T> implements Comparable<Request<T>>
{
    public String category;
    public String request;
    public int id;

    private transient boolean mCanceled;

    public transient long timeStamp;

    public transient int retryAttempts;

    public transient Object asyncLock;

    private transient final Class<T> type;

    public Request(Class<T> type) {
        this.type = type;
    }

    public T parseJsonResponse(JsonObject response, Gson gson)
    {
        if(GazeManager.IS_DEBUG_MODE)