public class DefaultSMSEngineRegistry extends java.lang.Object implements SMSEngineRegistry
| Constructor and Description |
|---|
DefaultSMSEngineRegistry() |
| Modifier and Type | Method and Description |
|---|---|
void |
addEngine(SMSEngine smsEngine) |
void |
afterPropertiesSet() |
protected AggregatorSettingsDTO |
createAggregatorSettings(MobileAggregatorModel aggregator) |
protected OutgoingSMSMessageDTO |
createMessageDTO(MobileMessageContextModel message) |
java.util.Set<SMSEngine> |
getAllEngines()
Returns all registered engines.
|
SMSEngine |
getEngine(EnginesType engine)
Returns a engine for a specific engine enum.
|
protected java.util.Map<EnginesType,java.util.Set<MobileAggregatorModel>> |
getEngineAggregators() |
boolean |
isAvailable(MobileAggregatorModel aggregator)
Checks if the engine for the given aggregator is actually available.
|
boolean |
isValidEngine(EnginesType engine)
Tells whether a given id is a valid
SMSEngine id. |
void |
removeEngine(SMSEngine engine) |
void |
send(MobileAggregatorModel aggregator,
MobileMessageContextModel message)
Performs sending using the appropriate engine for the specified aggregator and
the specified message.
|
void |
setCollectedEngines(java.util.Collection<SMSEngine> collectedEngines) |
void |
setFlexibleSearchService(FlexibleSearchService flexibleSearchService) |
void |
setModelService(ModelService modelService) |
void |
shutdownEngines()
Called to shut down engines once per tenant shutdown.
|
void |
startupEngines()
Called to start up engines once per tenant startup.
|
void |
updateEngines()
May be called to update engines with current aggregator settings.
|
public boolean isAvailable(MobileAggregatorModel aggregator)
SMSEngineRegistryisAvailable in interface SMSEngineRegistryaggregator - the aggregator to checkpublic void send(MobileAggregatorModel aggregator, MobileMessageContextModel message) throws SMSEngineException
SMSEngineRegistrysend in interface SMSEngineRegistryaggregator - the aggregator to specify the engine to be usedmessage - the message context item to useSMSEngineException - in case of sending errorpublic void startupEngines()
SMSEngineRegistrystartupEngines in interface SMSEngineRegistrypublic void shutdownEngines()
SMSEngineRegistryshutdownEngines in interface SMSEngineRegistrypublic void updateEngines()
SMSEngineRegistryupdateEngines in interface SMSEngineRegistryprotected AggregatorSettingsDTO createAggregatorSettings(MobileAggregatorModel aggregator)
protected OutgoingSMSMessageDTO createMessageDTO(MobileMessageContextModel message)
protected java.util.Map<EnginesType,java.util.Set<MobileAggregatorModel>> getEngineAggregators()
public java.util.Set<SMSEngine> getAllEngines()
SMSEngineRegistrygetAllEngines in interface SMSEngineRegistrypublic SMSEngine getEngine(EnginesType engine)
SMSEngineRegistrygetEngine in interface SMSEngineRegistrypublic boolean isValidEngine(EnginesType engine)
SMSEngineRegistrySMSEngine id.isValidEngine in interface SMSEngineRegistrypublic void addEngine(SMSEngine smsEngine)
public void removeEngine(SMSEngine engine)
public void setCollectedEngines(java.util.Collection<SMSEngine> collectedEngines)
public void afterPropertiesSet()
throws java.lang.Exception
java.lang.Exceptionpublic void setFlexibleSearchService(FlexibleSearchService flexibleSearchService)
public void setModelService(ModelService modelService)
Copyright © 2018 SAP SE. All Rights Reserved.