public class ODataConnectivityUtil extends Object
| Modifier and Type | Field and Description |
|---|---|
static String |
CSRF_HEADER |
static String |
SEPARATOR_PATH |
| Constructor and Description |
|---|
ODataConnectivityUtil() |
| Modifier and Type | Method and Description |
|---|---|
static org.apache.olingo.odata2.client.api.ep.Entity |
addPropertiesToEntity(Map<String,Object> properties,
org.apache.olingo.odata2.api.edm.EdmEntityType entityType) |
static void |
checkHttpStatus(org.apache.http.HttpResponse response,
ErrorResultHandler<?> errorHandler)
Checks the HttpStatus code and returns an ODataException object if it falls
between 400 and 599.
|
static void |
closeQuietly(org.apache.http.HttpResponse httpResponse,
org.apache.http.client.methods.HttpRequestBase request) |
static String |
convertKeyValuesToString(Map<String,Object> keys,
org.apache.olingo.odata2.api.edm.EdmEntityType entityType) |
static InputStream |
getObjectStream(Object entity) |
static EdmWithCSRF |
readMetadataWithCSRF(String serviceUri,
org.apache.http.client.HttpClient httpClient,
Map<String,String> headers,
ErrorResultHandler<?> errorHandler,
Boolean cacheMetadata,
URL metadataFilePath) |
static EdmWithCSRF |
readMetadataWithCSRF(String serviceUri,
org.apache.http.client.HttpClient httpClient,
Map<String,String> headers,
ErrorResultHandler<?> errorHandler,
Boolean cacheMetadata,
URL metadataFilePath,
com.sap.cloud.sdk.cloudplatform.cache.CacheKey cacheKey,
Boolean isCacheRefresh) |
static void |
safeCloseHttpResponse(org.apache.http.HttpResponse httpResponse)
Deprecated.
|
static String |
withSeparator(String separator,
String... parts) |
public static final String CSRF_HEADER
public static final String SEPARATOR_PATH
public static EdmWithCSRF readMetadataWithCSRF(String serviceUri, org.apache.http.client.HttpClient httpClient, Map<String,String> headers, ErrorResultHandler<?> errorHandler, Boolean cacheMetadata, URL metadataFilePath, com.sap.cloud.sdk.cloudplatform.cache.CacheKey cacheKey, Boolean isCacheRefresh) throws org.apache.http.client.ClientProtocolException, IOException, ODataException
org.apache.http.client.ClientProtocolExceptionIOExceptionODataExceptionpublic static EdmWithCSRF readMetadataWithCSRF(String serviceUri, org.apache.http.client.HttpClient httpClient, Map<String,String> headers, ErrorResultHandler<?> errorHandler, Boolean cacheMetadata, URL metadataFilePath) throws org.apache.http.client.ClientProtocolException, IOException, ODataException
org.apache.http.client.ClientProtocolExceptionIOExceptionODataExceptionpublic static String convertKeyValuesToString(Map<String,Object> keys, org.apache.olingo.odata2.api.edm.EdmEntityType entityType) throws ODataException, org.apache.olingo.odata2.api.edm.EdmException
ODataExceptionorg.apache.olingo.odata2.api.edm.EdmExceptionpublic static org.apache.olingo.odata2.client.api.ep.Entity addPropertiesToEntity(Map<String,Object> properties, org.apache.olingo.odata2.api.edm.EdmEntityType entityType) throws org.apache.olingo.odata2.api.edm.EdmException, ODataException
org.apache.olingo.odata2.api.edm.EdmExceptionODataExceptionpublic static void checkHttpStatus(org.apache.http.HttpResponse response,
ErrorResultHandler<?> errorHandler)
throws ODataException
response - HttpResponse objecterrorHandler - ODataExceptionpublic static void closeQuietly(org.apache.http.HttpResponse httpResponse,
org.apache.http.client.methods.HttpRequestBase request)
@Deprecated public static void safeCloseHttpResponse(org.apache.http.HttpResponse httpResponse)
public static InputStream getObjectStream(Object entity)
Copyright © 2020 SAP. All Rights Reserved.