VcapDataT
- The destination specific structure of the JSON data contained within the VCAP lookup.public abstract class ScpVcapDestinationLoader<VcapDataT extends ScpVcapDestinationLoader.ScpVcapServiceData> extends Object implements DestinationLoader
DestinationAccessor
.Modifier and Type | Class and Description |
---|---|
static interface |
ScpVcapDestinationLoader.ScpVcapServiceData
Destination specific structure of the JSON data contained within the VCAP lookup.
|
Constructor and Description |
---|
ScpVcapDestinationLoader() |
Modifier and Type | Method and Description |
---|---|
protected abstract Destination |
createDestination(VcapDataT vcapData,
DestinationOptions options)
Create an instance of
Destination from the structured data, which was retrieved from the VCAP lookup |
io.vavr.control.Try<Destination> |
tryGetDestination(String destinationName,
DestinationOptions options)
Retrieves a destination for the given name and configuration options.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
tryGetDestination
@Nonnull public io.vavr.control.Try<Destination> tryGetDestination(@Nonnull String destinationName, @Nonnull DestinationOptions options)
The returned Try
object will contain a
DestinationAccessException
with more details in
case something went wrong.
If the returned Try
object contains no Exception it will always contain a non-null Destination
value.
tryGetDestination
in interface DestinationLoader
destinationName
- The name of the destination to obtain.options
- Additional settings to modify the behaviour of the destination loader.Try
object containing either the non-null Destination
value or an exception.@Nonnull protected abstract Destination createDestination(@Nonnull VcapDataT vcapData, @Nonnull DestinationOptions options)
Destination
from the structured data, which was retrieved from the VCAP lookupvcapData
- The structured data which could be serialized from the JSON response of the VCAP lookup.options
- Additional settings to modify the behaviour of the destination creation.Destination
.Copyright © 2019 SAP SE. All rights reserved.