Class ODataRequestBuilder
java.lang.Object
de.hybris.platform.odata2webservices.odata.builders.ODataRequestBuilder
A builder to create
ODataRequests according to specifications in the tests.-
Method Summary
Modifier and TypeMethodDescriptionorg.apache.olingo.odata2.api.processor.ODataRequestbuild()static ODataRequestBuilderCreates new instance of the builder for building a DELETE request.static ODataRequestBuilderCreates new instance of the builder for building a GET request.static ODataRequestBuilderCreates new instance of the builder for building a PATCH request.static ODataRequestBuilderCreates new instance of the builder for building a POST request.withAcceptLanguage(Locale locale) withAccepts(String mediaType) withBody(JsonBuilder content) Specifies body for the POST request.Specifies body for the POST request.Specifies body for the POST requestwithContentLanguage(Locale locale) withContentType(String type) withHeader(String headerName, String... values) withParameter(String name, Object value) withParameters(String... paramNames) withParameters(Map<String, String> params) withPathInfo(PathInfoBuilder builder) withPathInfo(org.apache.olingo.odata2.core.PathInfoImpl info)
-
Method Details
-
oDataGetRequest
Creates new instance of the builder for building a GET request.- Returns:
- instance of the builder, which has no specifications done to it.
-
oDataPostRequest
Creates new instance of the builder for building a POST request.- Returns:
- instance of the builder, which has no specifications done to it.
-
oDataDeleteRequest
Creates new instance of the builder for building a DELETE request.- Returns:
- instance of the builder, which has no specifications done to it.
-
oDataPatchRequest
Creates new instance of the builder for building a PATCH request.- Returns:
- instance of the builder, which has no specifications done to it.
-
withAccepts
-
withAcceptLanguage
-
withContentLanguage
-
withContentType
-
withHeader
-
withParameters
-
withParameters
-
withParameter
-
withPathInfo
-
withPathInfo
-
withBody
Specifies body for the POST request. It's implied that UTF-8 encoding is used for the specified body.- Parameters:
content- a builder containing specification of the body to be sent as "application/json" content type.- Returns:
- a builder with the POST request body specified
-
withBody
Specifies body for the POST request. It's implied that UTF-8 encoding is used for the specified body.- Parameters:
content- content of the body- Returns:
- a builder with the POST request body specified
-
withBody
Specifies body for the POST request- Parameters:
content- content of the bodycharset- encoding of the body- Returns:
- a builder with the POST request body specified
-
build
public org.apache.olingo.odata2.api.processor.ODataRequest build()
-