public class GeckoApplicationContainer extends java.lang.Object implements ApplicationScheduler, ApplicationManager
| Constructor and Description |
|---|
GeckoApplicationContainer() |
| Modifier and Type | Method and Description |
|---|---|
void |
activate(ComponentContext context,
java.util.Map<java.lang.String,java.lang.Object> properties) |
void |
addApplicationDescriptor(ApplicationDescriptor descriptor)
Adds an
ApplicationDescriptor to the registry |
void |
deactivate() |
java.util.Set<java.lang.String> |
getActiveApplications()
Returns all id's of active application descriptors or an empty
Set |
java.util.Set<java.lang.String> |
getAllApplications()
Returns all id's of application descriptors or an empty
Set |
boolean |
lockApplication(java.lang.String applicationId)
Locks the application with the given id
|
void |
removeApplicationDescriptor(ApplicationDescriptor descriptor)
Removes an
ApplicationDescriptor from the registry |
ScheduledApplication |
schedule(ApplicationDescriptor descriptor,
java.lang.String scheduleId,
java.util.Map<java.lang.String,java.lang.Object> arguments,
java.lang.String topic,
java.lang.String eventFilter,
boolean recurring)
Schedules an application
|
ScheduledApplication |
scheduleApplication(java.lang.String applicationId,
java.util.Map<java.lang.String,java.lang.Object> launchProperties,
Filter scheduleFilter)
Uses the virtual timer of the system to schedule an application
|
boolean |
startApplication(java.lang.String applicationId,
java.util.Map<java.lang.String,java.lang.Object> launchProperties)
Starts the application with the given id
|
boolean |
stopApplication(java.lang.String applicationId)
Starts the application with the given id
|
boolean |
unlockApplication(java.lang.String applicationId)
Un-locks the application with the given id
|
void |
unschedule(java.lang.String scheduleId)
Un-schedules an application for the schedule id
|
boolean |
unscheduleApplication(java.lang.String applicationId)
Revokes the scheduling of an application
|
public void activate(ComponentContext context,
java.util.Map<java.lang.String,java.lang.Object> properties)
public void deactivate()
public void addApplicationDescriptor(ApplicationDescriptor descriptor)
ApplicationDescriptor to the registrydescriptor - the descriptor to be addedpublic void removeApplicationDescriptor(ApplicationDescriptor descriptor)
ApplicationDescriptor from the registrydescriptor - the descriptor to be removedpublic ScheduledApplication schedule(ApplicationDescriptor descriptor, java.lang.String scheduleId, java.util.Map<java.lang.String,java.lang.Object> arguments, java.lang.String topic, java.lang.String eventFilter, boolean recurring) throws InvalidSyntaxException, ApplicationException
ApplicationSchedulerschedule in interface ApplicationSchedulerdescriptor - the application descriptorscheduleId - the schedule idarguments - the handle argumentstopic - the event trigger topiceventFilter - the optional event filterrecurring - true, if the event occurs recurring on each eventScheduledApplication instanceInvalidSyntaxExceptionApplicationExceptionpublic void unschedule(java.lang.String scheduleId)
throws InvalidSyntaxException,
ApplicationException
ApplicationSchedulerunschedule in interface ApplicationSchedulerscheduleId - the id of the application to be removedInvalidSyntaxExceptionApplicationExceptionpublic java.util.Set<java.lang.String> getAllApplications()
ApplicationManagerSetgetAllApplications in interface ApplicationManagerSetpublic java.util.Set<java.lang.String> getActiveApplications()
ApplicationManagerSetgetActiveApplications in interface ApplicationManagerSetpublic boolean lockApplication(java.lang.String applicationId)
ApplicationManagerlockApplication in interface ApplicationManagerapplicationId - the application to locktrue on successpublic boolean unlockApplication(java.lang.String applicationId)
ApplicationManagerunlockApplication in interface ApplicationManagerapplicationId - the application to locktrue on successpublic boolean startApplication(java.lang.String applicationId,
java.util.Map<java.lang.String,java.lang.Object> launchProperties)
ApplicationManagerstartApplication in interface ApplicationManagerapplicationId - the application to startlaunchProperties - optional launch propertiestrue on successpublic boolean stopApplication(java.lang.String applicationId)
ApplicationManagerstopApplication in interface ApplicationManagerapplicationId - the application to starttrue on successpublic ScheduledApplication scheduleApplication(java.lang.String applicationId, java.util.Map<java.lang.String,java.lang.Object> launchProperties, Filter scheduleFilter)
ApplicationManagerscheduleApplication in interface ApplicationManagerapplicationId - the application to be runlaunchProperties - the launch propertiesscheduleFilter - the time based filterpublic boolean unscheduleApplication(java.lang.String applicationId)
ApplicationManagerunscheduleApplication in interface ApplicationManagerapplicationId - the application to be runtrue on successData In Motion Consulting GmbH