List of usage examples for com.google.gson.reflect TypeToken TypeToken
@SuppressWarnings("unchecked") protected TypeToken()
From source file:abtlibrary.utils.as24ApiClient.api.DealerGroupsApi.java
License:Apache License
/** * (asynchronously)/*from www. ja v a 2 s . c om*/ * * @param dealergroupId (required) * @param filter (required) * @param callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body object */ public com.squareup.okhttp.Call gETpublicV41DealergroupsDealergroupidMakesAsync(Integer dealergroupId, String filter, final ApiCallback<ResponseMessageListMake> callback) throws ApiException { ProgressResponseBody.ProgressListener progressListener = null; ProgressRequestBody.ProgressRequestListener progressRequestListener = null; if (callback != null) { progressListener = new ProgressResponseBody.ProgressListener() { @Override public void update(long bytesRead, long contentLength, boolean done) { callback.onDownloadProgress(bytesRead, contentLength, done); } }; progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { @Override public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { callback.onUploadProgress(bytesWritten, contentLength, done); } }; } com.squareup.okhttp.Call call = gETpublicV41DealergroupsDealergroupidMakesCall(dealergroupId, filter, progressListener, progressRequestListener); Type localVarReturnType = new TypeToken<ResponseMessageListMake>() { }.getType(); apiClient.executeAsync(call, localVarReturnType, callback); return call; }
From source file:abtlibrary.utils.as24ApiClient.api.DealerGroupsApi.java
License:Apache License
/** * //from w w w .j a va 2s . c o m * * @param dealergroupId (required) * @param filter (required) * @return ApiResponse<ResponseMessageListModel> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body */ public ApiResponse<ResponseMessageListModel> gETpublicV41DealergroupsDealergroupidModelsWithHttpInfo( Integer dealergroupId, String filter) throws ApiException { com.squareup.okhttp.Call call = gETpublicV41DealergroupsDealergroupidModelsCall(dealergroupId, filter, null, null); Type localVarReturnType = new TypeToken<ResponseMessageListModel>() { }.getType(); return apiClient.execute(call, localVarReturnType); }
From source file:abtlibrary.utils.as24ApiClient.api.DealerGroupsApi.java
License:Apache License
/** * (asynchronously)//from www .ja v a2s . co m * * @param dealergroupId (required) * @param filter (required) * @param callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body object */ public com.squareup.okhttp.Call gETpublicV41DealergroupsDealergroupidModelsAsync(Integer dealergroupId, String filter, final ApiCallback<ResponseMessageListModel> callback) throws ApiException { ProgressResponseBody.ProgressListener progressListener = null; ProgressRequestBody.ProgressRequestListener progressRequestListener = null; if (callback != null) { progressListener = new ProgressResponseBody.ProgressListener() { @Override public void update(long bytesRead, long contentLength, boolean done) { callback.onDownloadProgress(bytesRead, contentLength, done); } }; progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { @Override public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { callback.onUploadProgress(bytesWritten, contentLength, done); } }; } com.squareup.okhttp.Call call = gETpublicV41DealergroupsDealergroupidModelsCall(dealergroupId, filter, progressListener, progressRequestListener); Type localVarReturnType = new TypeToken<ResponseMessageListModel>() { }.getType(); apiClient.executeAsync(call, localVarReturnType, callback); return call; }
From source file:abtlibrary.utils.as24ApiClient.api.DealerPagesApi.java
License:Apache License
/** * // w w w . j a va2 s . co m * * @param accountId (required) * @return ApiResponse<ResponseMessageDealerPageDealer> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body */ public ApiResponse<ResponseMessageDealerPageDealer> gETpublicV41DealerpagesAccountidWithHttpInfo( Integer accountId) throws ApiException { com.squareup.okhttp.Call call = gETpublicV41DealerpagesAccountidCall(accountId, null, null); Type localVarReturnType = new TypeToken<ResponseMessageDealerPageDealer>() { }.getType(); return apiClient.execute(call, localVarReturnType); }
From source file:abtlibrary.utils.as24ApiClient.api.DealerPagesApi.java
License:Apache License
/** * (asynchronously)/* w w w . j a v a 2 s . c o m*/ * * @param accountId (required) * @param callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body object */ public com.squareup.okhttp.Call gETpublicV41DealerpagesAccountidAsync(Integer accountId, final ApiCallback<ResponseMessageDealerPageDealer> callback) throws ApiException { ProgressResponseBody.ProgressListener progressListener = null; ProgressRequestBody.ProgressRequestListener progressRequestListener = null; if (callback != null) { progressListener = new ProgressResponseBody.ProgressListener() { @Override public void update(long bytesRead, long contentLength, boolean done) { callback.onDownloadProgress(bytesRead, contentLength, done); } }; progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { @Override public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { callback.onUploadProgress(bytesWritten, contentLength, done); } }; } com.squareup.okhttp.Call call = gETpublicV41DealerpagesAccountidCall(accountId, progressListener, progressRequestListener); Type localVarReturnType = new TypeToken<ResponseMessageDealerPageDealer>() { }.getType(); apiClient.executeAsync(call, localVarReturnType, callback); return call; }
From source file:abtlibrary.utils.as24ApiClient.api.DealerPagesApi.java
License:Apache License
/** * /*w w w . ja v a 2 s .c o m*/ * * @param accountId (required) * @return ApiResponse<ResponseMessageDealerPageAbout> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body */ public ApiResponse<ResponseMessageDealerPageAbout> gETpublicV41DealerpagesAccountidAboutWithHttpInfo( Integer accountId) throws ApiException { com.squareup.okhttp.Call call = gETpublicV41DealerpagesAccountidAboutCall(accountId, null, null); Type localVarReturnType = new TypeToken<ResponseMessageDealerPageAbout>() { }.getType(); return apiClient.execute(call, localVarReturnType); }
From source file:abtlibrary.utils.as24ApiClient.api.DealerPagesApi.java
License:Apache License
/** * (asynchronously)// w w w.ja va 2 s.c om * * @param accountId (required) * @param callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body object */ public com.squareup.okhttp.Call gETpublicV41DealerpagesAccountidAboutAsync(Integer accountId, final ApiCallback<ResponseMessageDealerPageAbout> callback) throws ApiException { ProgressResponseBody.ProgressListener progressListener = null; ProgressRequestBody.ProgressRequestListener progressRequestListener = null; if (callback != null) { progressListener = new ProgressResponseBody.ProgressListener() { @Override public void update(long bytesRead, long contentLength, boolean done) { callback.onDownloadProgress(bytesRead, contentLength, done); } }; progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { @Override public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { callback.onUploadProgress(bytesWritten, contentLength, done); } }; } com.squareup.okhttp.Call call = gETpublicV41DealerpagesAccountidAboutCall(accountId, progressListener, progressRequestListener); Type localVarReturnType = new TypeToken<ResponseMessageDealerPageAbout>() { }.getType(); apiClient.executeAsync(call, localVarReturnType, callback); return call; }
From source file:abtlibrary.utils.as24ApiClient.api.DealerPagesApi.java
License:Apache License
/** * /*from w ww . j av a2s.c o m*/ * * @param accountId (required) * @param skip (required) * @param take (required) * @param filter (optional) * @return ApiResponse<ResponseMessageCollectionListDealerPageDealer> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body */ public ApiResponse<ResponseMessageCollectionListDealerPageDealer> gETpublicV41DealerpagesAccountidAgenciesWithHttpInfo( Integer accountId, Integer skip, Integer take, String filter) throws ApiException { com.squareup.okhttp.Call call = gETpublicV41DealerpagesAccountidAgenciesCall(accountId, skip, take, filter, null, null); Type localVarReturnType = new TypeToken<ResponseMessageCollectionListDealerPageDealer>() { }.getType(); return apiClient.execute(call, localVarReturnType); }
From source file:abtlibrary.utils.as24ApiClient.api.DealerPagesApi.java
License:Apache License
/** * (asynchronously)// w ww . j av a2 s . co m * * @param accountId (required) * @param skip (required) * @param take (required) * @param filter (optional) * @param callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body object */ public com.squareup.okhttp.Call gETpublicV41DealerpagesAccountidAgenciesAsync(Integer accountId, Integer skip, Integer take, String filter, final ApiCallback<ResponseMessageCollectionListDealerPageDealer> callback) throws ApiException { ProgressResponseBody.ProgressListener progressListener = null; ProgressRequestBody.ProgressRequestListener progressRequestListener = null; if (callback != null) { progressListener = new ProgressResponseBody.ProgressListener() { @Override public void update(long bytesRead, long contentLength, boolean done) { callback.onDownloadProgress(bytesRead, contentLength, done); } }; progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { @Override public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { callback.onUploadProgress(bytesWritten, contentLength, done); } }; } com.squareup.okhttp.Call call = gETpublicV41DealerpagesAccountidAgenciesCall(accountId, skip, take, filter, progressListener, progressRequestListener); Type localVarReturnType = new TypeToken<ResponseMessageCollectionListDealerPageDealer>() { }.getType(); apiClient.executeAsync(call, localVarReturnType, callback); return call; }
From source file:abtlibrary.utils.as24ApiClient.api.DealerPagesApi.java
License:Apache License
/** * /*from w w w . ja va 2 s . c o m*/ * * @param accountId (required) * @return ApiResponse<ResponseMessageDealerPageContact> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body */ public ApiResponse<ResponseMessageDealerPageContact> gETpublicV41DealerpagesAccountidContactWithHttpInfo( Integer accountId) throws ApiException { com.squareup.okhttp.Call call = gETpublicV41DealerpagesAccountidContactCall(accountId, null, null); Type localVarReturnType = new TypeToken<ResponseMessageDealerPageContact>() { }.getType(); return apiClient.execute(call, localVarReturnType); }