Class ServiceBrokerRequest
java.lang.Object
org.springframework.cloud.servicebroker.model.ServiceBrokerRequest
- Direct Known Subclasses:
AsyncServiceBrokerRequest
,GetLastServiceBindingOperationRequest
,GetLastServiceOperationRequest
,GetServiceInstanceBindingRequest
,GetServiceInstanceRequest
Details common to all service broker requests.
- Author:
- Scott Frederick, Roy Clarkson
-
Field Summary
Modifier and TypeFieldDescriptionstatic final String
API Info Location header.protected String
static final String
Binding ID path variable name.static final String
Instance ID path variable name.static final String
API Originating Identity header.protected Context
static final String
Plan ID parameter name.static final String
Platform Instance ID variable name.protected String
static final String
API Request Identity header.protected String
static final String
Service ID parameter name. -
Constructor Summary
ModifierConstructorDescriptionConstruct a newServiceBrokerRequest
.protected
ServiceBrokerRequest
(String platformInstanceId, String apiInfoLocation, Context originatingIdentity, String requestIdentity) Construct a newServiceBrokerRequest
. -
Method Summary
Modifier and TypeMethodDescriptionboolean
Is another object type compatible with this object.boolean
Get the location of the API info endpoint of the platform instance.Get the identity of the user that initiated the request from the platform.Get the ID used to identify the platform instance.Get the identify of the request that was sent from the platform.int
hashCode()
void
setApiInfoLocation
(String apiInfoLocation) This method is intended to be used internally only; use a builder to construct an object of this type and set all field values.void
setOriginatingIdentity
(Context originatingIdentity) This method is intended to be used internally only; use a builder to construct an object of this type and set all field values.void
setPlatformInstanceId
(String platformInstanceId) This method is intended to be used internally only; use a builder to construct an object of this type and set all field values.void
setRequestIdentity
(String requestIdentity) For internal use only; use a builder to construct an object of this type and set all field values.toString()
-
Field Details
-
API_INFO_LOCATION_HEADER
API Info Location header.- See Also:
-
ORIGINATING_IDENTITY_HEADER
API Originating Identity header.- See Also:
-
REQUEST_IDENTITY_HEADER
API Request Identity header.- See Also:
-
INSTANCE_ID_PATH_VARIABLE
Instance ID path variable name.- See Also:
-
BINDING_ID_PATH_VARIABLE
Binding ID path variable name.- See Also:
-
SERVICE_ID_PARAMETER
Service ID parameter name.- See Also:
-
PLAN_ID_PARAMETER
Plan ID parameter name.- See Also:
-
PLATFORM_INSTANCE_ID_VARIABLE
Platform Instance ID variable name.- See Also:
-
platformInstanceId
-
apiInfoLocation
-
originatingIdentity
-
requestIdentity
-
-
Constructor Details
-
ServiceBrokerRequest
public ServiceBrokerRequest()Construct a newServiceBrokerRequest
. -
ServiceBrokerRequest
protected ServiceBrokerRequest(String platformInstanceId, String apiInfoLocation, Context originatingIdentity, String requestIdentity) Construct a newServiceBrokerRequest
.- Parameters:
platformInstanceId
- the platform instance IDapiInfoLocation
- location of the API info endpoint of the platform instanceoriginatingIdentity
- identity of the user that initiated the request from the platformrequestIdentity
- identity of the request being sent from the platform
-
-
Method Details
-
getPlatformInstanceId
Get the ID used to identify the platform instance.This is useful when the service broker is registered to multiple instances of a platform.
This value is set from any path element that precedes /v2 in the request from the platform. Will be null if the service broker is not registered with an instance ID in the registration URL.
- Returns:
- the platform instance ID, or null if not provided
-
setPlatformInstanceId
This method is intended to be used internally only; use a builder to construct an object of this type and set all field values.- Parameters:
platformInstanceId
- the platform instance ID
-
getApiInfoLocation
Get the location of the API info endpoint of the platform instance.This endpoint can be used to retrieve additional information about the platform making the request on platforms that support the header.
This value is set from the X-Api-Info-Location header in the request from the platform.
- Returns:
- the API info endpoint location, or null if not provided
-
setApiInfoLocation
This method is intended to be used internally only; use a builder to construct an object of this type and set all field values.- Parameters:
apiInfoLocation
- location of the API info endpoint of the platform instance
-
getOriginatingIdentity
Get the identity of the user that initiated the request from the platform.This value is set from the X-Broker-API-Originating-Identity header in the request from the platform.
- Returns:
- the user identity, or null if not provided
-
setOriginatingIdentity
This method is intended to be used internally only; use a builder to construct an object of this type and set all field values.- Parameters:
originatingIdentity
- identity of the user that initiated the request from the platform
-
getRequestIdentity
Get the identify of the request that was sent from the platform.This value is set from the X-Broker-API-Request-Identity header in the request from the platform
- Returns:
- the request identity, or null if not provided
-
setRequestIdentity
For internal use only; use a builder to construct an object of this type and set all field values.- Parameters:
requestIdentity
- identify of the request sent from the platform
-
equals
-
canEqual
Is another object type compatible with this object.- Parameters:
other
- the other object- Returns:
- true of compatible
-
hashCode
public int hashCode() -
toString
-