Package com.chargehound.net
Class ApiRequestor
java.lang.Object
com.chargehound.net.ApiRequestor
public class ApiRequestor
extends java.lang.Object
-
Constructor Summary
Constructors Constructor Description ApiRequestor(Chargehound chargehound) -
Method Summary
Modifier and Type Method Description com.google.api.client.http.HttpResponserequest(java.lang.String method, java.lang.String path)Make an http request to the Chargehound API.com.google.api.client.http.HttpResponserequest(java.lang.String method, java.lang.String path, java.util.Map<java.lang.String,java.lang.Object> params)Make an http request to the Chargehound API.com.google.api.client.http.HttpResponserequest(java.lang.String method, java.lang.String path, java.util.Map<java.lang.String,java.lang.Object> params, com.google.api.client.json.GenericJson data)Make an http request to the Chargehound API.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Constructor Details
-
ApiRequestor
-
-
Method Details
-
request
public com.google.api.client.http.HttpResponse request(java.lang.String method, java.lang.String path, java.util.Map<java.lang.String,java.lang.Object> params, com.google.api.client.json.GenericJson data) throws ChargehoundExceptionMake an http request to the Chargehound API.- Parameters:
method- the http methodpath- the URL pathparams- the query parametersdata- the request body data- Returns:
- HttpResponse
- Throws:
ChargehoundException- Exception on failed API request
-
request
public com.google.api.client.http.HttpResponse request(java.lang.String method, java.lang.String path) throws ChargehoundExceptionMake an http request to the Chargehound API.- Parameters:
method- the http methodpath- the URL path- Returns:
- HttpResponse
- Throws:
ChargehoundException- Exception on failed API request
-
request
public com.google.api.client.http.HttpResponse request(java.lang.String method, java.lang.String path, java.util.Map<java.lang.String,java.lang.Object> params) throws ChargehoundExceptionMake an http request to the Chargehound API.- Parameters:
method- the http methodpath- the URL pathparams- the query parameters- Returns:
- HttpResponse
- Throws:
ChargehoundException- Exception on failed API request
-