public interface CPAInboundRuntimeLookupManager
The CPA cache service offers two kinds of lookup mechanisms. One is
offered for such adapters, which need to start an own instance, for each
Channel configuration. Such adapters use the LookupManager
singleton class to read all known Channel configurations for their own
adapter type from the cache at startup, to start an instance of the adapter
for each Channel. These adapter types should also register themselves to
the CallbackController
, in order to be informed about new and
deleted Channel configurations.
The other type of adapters has only one running instance, which can
handle all messages, Channel-independent. These adapters need to retrieve
the Channel configuration per Message at runtime, based on the addressing
information in the header of the currently processed message. The
InboundRuntimeLookup
and InboundRuntimeLookup
objects
allow to retrieve Channel attribute values by checking internally, if a
matching Binding (sender or receiver agreement) exists. The adapter
type/namespace and the given addressing data of the message (from/to
Party/Service and Interface[Namespace]) need to be passed into the
constructor. After constuction the Inbound/OutboundRuntimeLookup either
the Channel object can be retrieved for further processing, or the
configuration values can be retrieved directly by name, as defined in
the adapter type meta data (schema).
InboundRuntimeLookup lookup = new InboundRuntimeLookup("MyAdapterName",
"http://mycompany.com/myadapter/namespace", "fromParty", "toParty",
"fromService", "toService", "interface", "interfaceNamespace");
int value = lookup.getChannelValueAsInt("IntValueName");
OutboundRuntimeLookup
,
LookupManager
Modifier and Type | Method and Description |
---|---|
Binding |
getBinding()
Returns the inbound Binding object for the message header fields, given
in the constuctor.
|
Object |
getBindingValue(String valueName)
Returns the Binding attribute value for the given name as Object.
|
BinaryData |
getBindingValueAsBinary(String valueName)
Returns the Binding attribute value for the given name as
BinaryData.
|
boolean |
getBindingValueAsBoolean(String valueName)
Returns the Binding attribute value for the given name as Boolean.
|
int |
getBindingValueAsInt(String valueName)
Returns the Binding attribute value for the given name as Integer.
|
long |
getBindingValueAsLong(String valueName)
Returns the Binding attribute value for the given name as Long.
|
String |
getBindingValueAsString(String valueName)
Returns the Binding attribute value for the given name as String.
|
TableData |
getBindingValueAsTable(String valueName)
Returns the Binding attribute value for the given name as
TableData.
|
Channel |
getChannel()
Returns the Channel object for the given Binding.
|
Channel |
getChannelObject(Binding binding) |
Object |
getChannelValue(String valueName)
Returns the Channel attribute value for the given name as Object.
|
BinaryData |
getChannelValueAsBinary(String valueName)
Returns the Channel attribute value for the given name as
BinaryData.
|
boolean |
getChannelValueAsBoolean(String valueName)
Returns the Channel attribute value for the given name as Boolean.
|
int |
getChannelValueAsInt(String valueName)
Returns the Channel attribute value for the given name as Integer.
|
long |
getChannelValueAsLong(String valueName)
Returns the Channel attribute value for the given name as Long.
|
String |
getChannelValueAsString(String valueName)
Returns the Channel attribute value for the given name as String.
|
TableData |
getChannelValueAsTable(String valueName)
Returns the Channel attribute value for the given name as
TableData.
|
Binding |
getInboundBinding()
Same as calling
CPAInboundRuntimeLookupManager#getInboundBinding(boolean); with parameter value ignore==false |
Binding |
getInboundBinding(boolean ignore)
Depending on the
CacheManager initialization, this method
returns the Binding object as configured in the constructor,
either from the memory cache, or directly from the database. |
Binding |
getOutboundBinding()
Same as calling
CPAInboundRuntimeLookupManager#getOutboundBinding(boolean); with parameter value ignore==false |
Binding |
getOutboundBinding(boolean ignore)
Depending on the
CacheManager initialization, this method
returns the Binding object as configured in the constructor,
either from the memory cache, or directly from the database. |
boolean |
isBindingValuePassword(String valueName)
Returns if a given Binding attribute value is a password field, or not.
|
boolean |
isChannelValuePassword(String valueName)
Returns if a given Channel attribute value is a password field, or not.
|
Object getChannelValue(String valueName) throws CPAException
valueName
- the name of a channel attributeCPAException
- in case that no such Channel attribute
can be retrieved.String getChannelValueAsString(String valueName) throws CPAException
valueName
- the name of a channel attributeCPAException
- in case that no such Channel attribute
can be retrieved.int getChannelValueAsInt(String valueName) throws CPAException
valueName
- the name of a channel attributeCPAException
- in case that no such Channel attribute
can be retrieved.long getChannelValueAsLong(String valueName) throws CPAException
valueName
- the name of a channel attributeCPAException
- in case that no such Channel attribute
can be retrieved.boolean getChannelValueAsBoolean(String valueName) throws CPAException
valueName
- the name of a channel attributeCPAException
- in case that no such Channel attribute
can be retrieved.BinaryData getChannelValueAsBinary(String valueName) throws CPAException
valueName
- the name of a channel attributeCPAException
- in case that no such Channel attribute
can be retrieved.TableData getChannelValueAsTable(String valueName) throws CPAException
valueName
- the name of a channel attributeCPAException
- in case that no such Channel attribute
can be retrieved.Object getBindingValue(String valueName) throws CPAException
valueName
- the name of a binding attributeCPAException
- in case that no such Binding attribute
can be retrieved.String getBindingValueAsString(String valueName) throws CPAException
valueName
- the name of a binding attributeCPAException
- in case that no such Binding attribute
can be retrieved.int getBindingValueAsInt(String valueName) throws CPAException
valueName
- the name of a binding attributeCPAException
- in case that no such Binding attribute
can be retrieved.long getBindingValueAsLong(String valueName) throws CPAException
valueName
- the name of a binding attributeCPAException
- in case that no such Binding attribute
can be retrieved.boolean getBindingValueAsBoolean(String valueName) throws CPAException
valueName
- the name of a binding attributeCPAException
- in case that no such Binding attribute
can be retrieved.BinaryData getBindingValueAsBinary(String valueName) throws CPAException
valueName
- the name of a binding attributeCPAException
- in case that no such Binding attribute
can be retrieved.TableData getBindingValueAsTable(String valueName) throws CPAException
valueName
- the name of a binding attributeCPAException
- in case that no such Binding attribute
can be retrieved.Binding getBinding() throws CPAException
CPAException
- in case that no inbound Binding can be
retrieved.Channel getChannel() throws CPAException
CPAException
- in case that no such Channel can be
retrieved.boolean isChannelValuePassword(String valueName) throws CPAException
valueName
- the name of a channel attributeCPAException
- in case that no such Channel attribute
can be retrieved.boolean isBindingValuePassword(String valueName) throws CPAException
valueName
- the name of a channel attributeCPAException
- in case that no such Binding attribute
can be retrieved.Channel getChannelObject(Binding binding) throws CPAException
binding
- A binding object which is associated with the desired channelCPAException
- in case that no such Channel can be retrieved.Binding getInboundBinding() throws CPAException
CPAInboundRuntimeLookupManager#getInboundBinding(boolean);
with parameter value ignore==falseBinding
object as configured in the
constructor.CPAException
- in case that no such
Binding
object can be retrieved.getInboundBinding(boolean)
Binding getInboundBinding(boolean ignore) throws CPAException
CacheManager
initialization, this method
returns the Binding
object as configured in the constructor,
either from the memory cache, or directly from the database. Internally it
uses the getMostSpecific method provided by the aii_util_misc package.ignore
- If this flag is true, the method will return null, if no
binding is configured, instead of throwing an exception.Binding
object as configured in the
constructor.CPAException
- in case that no such
Binding
object can be retrieved.Binding getOutboundBinding() throws CPAException
CPAInboundRuntimeLookupManager#getOutboundBinding(boolean);
with parameter value ignore==falseBinding
object as configured in the constructor.CPAException
- in case that no such
Binding
object can be retrieved.getOutboundBinding(boolean)
Binding getOutboundBinding(boolean ignore) throws CPAException
CacheManager
initialization, this method
returns the Binding
object as configured in the constructor,
either from the memory cache, or directly from the database. Internally it
uses the getMostSpecific method provided by the aii_util_misc package.ignore
- If this flag is true, the method will return null, if no
binding is configured, instead of throwing an exception.Binding
object as configured in the constructor.CPAException
- in case that no such
Binding
object can be retrieved.Access Rights |
---|
SC | DC | Public Part | ACH |
---|---|---|---|
[sap.com] SAP_XIAF
|
[sap.com] com.sap.aii.af.svc.facade
|
api
|
BC-XI
|
Copyright 2019 SAP AG Complete Copyright Notice