Class ErpHttpDestinationUtils
java.lang.Object
com.sap.cloud.sdk.s4hana.connectivity.ErpHttpDestinationUtils
Collection of convenience methods to work with
ErpHttpDestinations.-
Method Summary
Modifier and TypeMethodDescriptionasErp()Convenience method to decorate a genericHttpDestinationinto an ERP specificErpHttpDestination.static ErpHttpDestinationgetErpHttpDestination(String destinationName) Convenience method to retrieve a destination by name via theDestinationAccessorand decorating it as aErpHttpDestination.
-
Method Details
-
getErpHttpDestination
@Nonnull public static ErpHttpDestination getErpHttpDestination(@Nonnull String destinationName) throws DestinationAccessException, IllegalArgumentException Convenience method to retrieve a destination by name via theDestinationAccessorand decorating it as aErpHttpDestination.- Parameters:
destinationName- The name of the destination to retrieve.- Returns:
- The destination with the given name as an
ErpHttpDestination. - Throws:
DestinationAccessException- if the destination with the given name could not be found.IllegalArgumentException- if the destination with the given name is noHttpDestination.
-
asErp
Convenience method to decorate a genericHttpDestinationinto an ERP specificErpHttpDestination.- Returns:
- A function that can be used in the
HttpDestination.decorate(Function)to create aErpHttpDestination.
-