public class RpcSAClientImpl extends AbstractSAClient
SAClient.parameters, running| Modifier and Type | Method and Description |
|---|---|
ModuleURN |
createStrategy(CreateStrategyParameters inParameters)
Creates a new strategy module using the given strategy creation parameters.
|
void |
delete(ModuleURN inURN)
Deletes the module instance having the supplied URN.
|
protected void |
doStart()
Execute on start.
|
protected void |
doStop()
Execute on stop.
|
ContextClassProvider |
getContextClassProvider()
Get the contextClassProvider value.
|
List<ModuleURN> |
getInstances(ModuleURN inProviderURN)
Returns the list of module instances available.
|
ModuleInfo |
getModuleInfo(ModuleURN inURN)
Returns the module information for the module instance with the supplied URN.
|
Map<String,Object> |
getProperties(ModuleURN inURN)
Fetches all the available properties of the module with the supplied URN.
|
List<ModuleURN> |
getProviders()
Returns the list of providers available.
|
CreateStrategyParameters |
getStrategyCreateParms(ModuleURN inURN)
Fetches the strategy creation parameters (including the strategy script)
for the strategy with the supplied URN.
|
void |
sendData(Object inData)
Sends the given object to the Strategy Agent where registered listeners will receive it.
|
void |
setContextClassProvider(ContextClassProvider inContextClassProvider)
Sets the contextClassProvider value.
|
Map<String,Object> |
setProperties(ModuleURN inURN,
Map<String,Object> inProperties)
Sets the supplied properties of the module.
|
void |
start(ModuleURN inURN)
Starts the module instance having the supplied URN.
|
void |
stop(ModuleURN inURN)
Stops the module instance having the supplied URN.
|
addConnectionStatusListener, addDataReceiver, close, connectionStatusChanged, failIfClosed, failIfDisconnected, getParameters, isRunning, receiveData, removeConnectionStatusListener, removeDataReciever, start, stop, wrapRemoteFailurepublic List<ModuleURN> getProviders() throws ConnectionException
SAClientIf no providers are available this list is empty.
ConnectionException - if there were errors completing the operation.public List<ModuleURN> getInstances(ModuleURN inProviderURN) throws ConnectionException
SAClientIf no instances are found, an empty list is returned.
inProviderURN - the URN of the provider whose instances should be returned. If null, all available instances are returned.ConnectionException - if there were errors completing the operation.public ModuleInfo getModuleInfo(ModuleURN inURN) throws ConnectionException
SAClientinURN - the module instance URN. Cannot be null.ConnectionException - if there were errors completing the operation.public void start(ModuleURN inURN) throws ConnectionException
SAClientOnly strategy module instances can be started. Attempts to start modules that are not strategy modules will fail.
inURN - the URN of the module that needs to be started. Cannot be null.ConnectionException - if there were errors completing the operation.public void stop(ModuleURN inURN) throws ConnectionException
SAClientOnly strategy module instances can be stopped. Attempts to stop modules that are not strategy modules will fail.
inURN - the URN of the module that needs to be stopped. Cannot be null.ConnectionException - if there were errors completing the operation.public void delete(ModuleURN inURN) throws ConnectionException
SAClientOnly strategy module instances can be deleted. Attempts to delete modules that are not strategy modules will fail.
inURN - the URN of the module that needs to be deleted. Cannot be null.ConnectionException - if there were errors completing the operation.public Map<String,Object> getProperties(ModuleURN inURN) throws ConnectionException
SAClient
Note that the property values may not be in the same type as is
declared on the module's MXBean. The return types are open data types.
Refer to the type mapping rules in MXBean
documentation to figure out the return type for a particular property
type. For example, enum property types are returned as string values.
inURN - the module URN. Cannot be null.ConnectionException - if there were errors completing the operation.public Map<String,Object> setProperties(ModuleURN inURN, Map<String,Object> inProperties) throws ConnectionException
SAClientOnly the following properties of strategy module can be set. Attempts to set the properties of a module that is not a strategy module or a strategy module property that is not in this list will fail.
RemoteProperties instance that has
details on the error encountered when setting the property.inURN - the URN of the module whose properties are being set. Cannot be null.inProperties - the new property values for the module. Cannot be null.RemoteProperties
instance that has details on the failure.ConnectionException - if there were errors completing the operation.public ModuleURN createStrategy(CreateStrategyParameters inParameters) throws ConnectionException
SAClientinParameters - the strategy creation parameters. Cannot be null.ConnectionException - if there were errors completing the operation.public CreateStrategyParameters getStrategyCreateParms(ModuleURN inURN) throws ConnectionException
SAClient
This method is made available to enable a client to export strategy
script contents. It's recommended that SAClient.getProperties(ModuleURN)
be used for fetching the current values of strategy properties as
SAClient.getStrategyCreateParms(org.marketcetera.module.ModuleURN)
may yield stale values for certain strategy attributes like
parameters.
inURN - the strategy module instnace URN. Cannot be null.ConnectionException - if there were errors completing the operation.public void sendData(Object inData) throws ConnectionException
SAClientinData - an Object valueConnectionException - if there were errors completing the operation.public ContextClassProvider getContextClassProvider()
ContextClassProvider valuepublic void setContextClassProvider(ContextClassProvider inContextClassProvider)
inContextClassProvider - a ContextClassProvider valueprotected void doStart()
AbstractSAClientdoStart in class AbstractSAClientprotected void doStop()
AbstractSAClientdoStop in class AbstractSAClientCopyright © 2017. All Rights Reserved.