Package com.microsoft.graph.http
Class PrimitiveRequest<T>
java.lang.Object
com.microsoft.graph.http.BaseRequest<T>
com.microsoft.graph.http.PrimitiveRequest<T>
- Type Parameters:
T- the primitive type to deserialize the response to
- All Implemented Interfaces:
IHttpRequest
The class for the Primitive Request.
-
Field Summary
Fields inherited from class com.microsoft.graph.http.BaseRequest
functionOptions, queryOptions, REQUEST_STATS_HEADER_VALUE_FORMAT_STRING -
Constructor Summary
ConstructorsConstructorDescriptionPrimitiveRequest(String requestUrl, IBaseClient<?> client, List<? extends Option> requestOptions, Class<T> primitiveTypeClass)The request for the primitive type -
Method Summary
Methods inherited from class com.microsoft.graph.http.BaseRequest
addCountOption, addExpandOption, addFilterOption, addFunctionOption, addHeader, addOrderByOption, addQueryOption, addSelectOption, addSkipOption, addSkipTokenOption, addTopOption, getClient, getDelay, getFunctionOptions, getHeaders, getHttpMethod, getHttpRequest, getMaxRedirects, getMaxRetries, getOptions, getQueryOptions, getRequestUrl, getResponseType, getShouldRedirect, getShouldRetry, getUseCaches, send, sendAsync, setDelay, setHttpMethod, setMaxRedirects, setMaxRetries, setShouldRedirect, setShouldRetry, setUseCaches, withHttpMethodMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.microsoft.graph.http.IHttpRequest
getHttpRequest
-
Constructor Details
-
PrimitiveRequest
public PrimitiveRequest(@Nonnull String requestUrl, @Nonnull IBaseClient<?> client, @Nullable List<? extends Option> requestOptions, @Nonnull Class<T> primitiveTypeClass)The request for the primitive type- Parameters:
requestUrl- the request URLclient- the service clientrequestOptions- the options for this requestprimitiveTypeClass- the return type class for the request
-
-
Method Details
-
getAsync
Gets the primitive information from the service- Returns:
- a future with the result
-
get
Gets the primitive information from the service- Returns:
- the primitive information from the request
- Throws:
ClientException- this exception occurs if the request was unable to complete for any reason
-