org.jbpm.process.core.timer.impl

## Class GlobalTimerService

- java.lang.Object
- - org.jbpm.process.core.timer.impl.GlobalTimerService

- All Implemented Interfaces:
    org.drools.core.time.InternalSchedulerService, org.drools.core.time.SchedulerService, org.drools.core.time.TimerService

      public class GlobalTimerService
      extends Object
      implements org.drools.core.time.TimerService, org.drools.core.time.InternalSchedulerService

- - ### Nested Class Summary

    Nested Classes
    Modifier and Type | Class and Description
    --- | ---
    `static class` | `GlobalTimerService.DisposableCommandService`
    `static class` | `GlobalTimerService.GlobalJobHandle`

  - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `protected org.drools.core.time.impl.TimerJobFactoryManager` | `jobFactoryManager`
    `protected org.kie.api.runtime.manager.RuntimeManager` | `manager`
    `protected GlobalSchedulerService` | `schedulerService`
    `protected ConcurrentHashMap<Long,List<GlobalTimerService.GlobalJobHandle>>` | `timerJobsPerSession`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `GlobalTimerService(org.kie.api.runtime.manager.RuntimeManager manager, GlobalSchedulerService schedulerService)`

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `org.drools.core.time.JobHandle` | `buildJobHandleForContext(NamedJobContext ctx)`
    `void` | `destroy()`
    `org.drools.core.command.CommandService` | `getCommandService(org.drools.core.time.JobContext jobContext)`
    `protected org.drools.core.command.CommandService` | `getCommandService(Long processInstanceId, TimerManager.ProcessJobContext ctx)`
    `long` | `getCurrentTime()`
    `org.kie.internal.runtime.manager.InternalRuntimeManager` | `getRuntimeManager()`
    `org.drools.core.time.impl.TimerJobFactoryManager` | `getTimerJobFactoryManager()`
    `Collection<org.drools.core.time.impl.TimerJobInstance>` | `getTimerJobInstances(long id)`
    `String` | `getTimerServiceId()`
    `long` | `getTimeToNextJob()`
    `void` | `internalSchedule(org.drools.core.time.impl.TimerJobInstance timerJobInstance)`
    `boolean` | `removeJob(org.drools.core.time.JobHandle jobHandle)`
    `org.drools.core.time.JobHandle` | `scheduleJob(org.drools.core.time.Job job, org.drools.core.time.JobContext ctx, org.drools.core.time.Trigger trigger)`
    `void` | `setTimerJobFactoryManager(org.drools.core.time.impl.TimerJobFactoryManager timerJobFactoryManager)`
    `void` | `setTimerServiceId(String timerServiceId)`
    `void` | `shutdown()`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Field Detail

    - #### jobFactoryManager

          protected org.drools.core.time.impl.TimerJobFactoryManager jobFactoryManager

    - #### schedulerService

          protected GlobalSchedulerService schedulerService

    - #### manager

          protected org.kie.api.runtime.manager.RuntimeManager manager

    - #### timerJobsPerSession

          protected ConcurrentHashMap<Long,List<GlobalTimerService.GlobalJobHandle>> timerJobsPerSession

  - ### Constructor Detail

    - #### GlobalTimerService

          public GlobalTimerService(org.kie.api.runtime.manager.RuntimeManager manager,
                            GlobalSchedulerService schedulerService)

  - ### Method Detail

    - #### scheduleJob

          public org.drools.core.time.JobHandle scheduleJob(org.drools.core.time.Job job,
                                                   org.drools.core.time.JobContext ctx,
                                                   org.drools.core.time.Trigger trigger)

      Specified by:
        `scheduleJob` in interface `org.drools.core.time.SchedulerService`

    - #### removeJob

          public boolean removeJob(org.drools.core.time.JobHandle jobHandle)

      Specified by:
        `removeJob` in interface `org.drools.core.time.SchedulerService`

    - #### getCurrentTime

          public long getCurrentTime()

      Specified by:
        `getCurrentTime` in interface `org.drools.core.time.TimerService`

    - #### shutdown

          public void shutdown()

      Specified by:
        `shutdown` in interface `org.drools.core.time.TimerService`

    - #### destroy

          public void destroy()

    - #### getTimeToNextJob

          public long getTimeToNextJob()

      Specified by:
        `getTimeToNextJob` in interface `org.drools.core.time.TimerService`

    - #### getTimerJobInstances

          public Collection<org.drools.core.time.impl.TimerJobInstance> getTimerJobInstances(long id)

      Specified by:
        `getTimerJobInstances` in interface `org.drools.core.time.TimerService`

    - #### internalSchedule

          public void internalSchedule(org.drools.core.time.impl.TimerJobInstance timerJobInstance)

      Specified by:
        `internalSchedule` in interface `org.drools.core.time.InternalSchedulerService`

    - #### setTimerJobFactoryManager

          public void setTimerJobFactoryManager(org.drools.core.time.impl.TimerJobFactoryManager timerJobFactoryManager)

      Specified by:
        `setTimerJobFactoryManager` in interface `org.drools.core.time.TimerService`

    - #### getTimerJobFactoryManager

          public org.drools.core.time.impl.TimerJobFactoryManager getTimerJobFactoryManager()

      Specified by:
        `getTimerJobFactoryManager` in interface `org.drools.core.time.TimerService`

    - #### getCommandService

          public org.drools.core.command.CommandService getCommandService(org.drools.core.time.JobContext jobContext)

    - #### getTimerServiceId

          public String getTimerServiceId()

    - #### setTimerServiceId

          public void setTimerServiceId(String timerServiceId)

    - #### buildJobHandleForContext

          public org.drools.core.time.JobHandle buildJobHandleForContext(NamedJobContext ctx)

    - #### getRuntimeManager

          public org.kie.internal.runtime.manager.InternalRuntimeManager getRuntimeManager()

    - #### getCommandService

          protected org.drools.core.command.CommandService getCommandService(Long processInstanceId,
                                                                 TimerManager.ProcessJobContext ctx)

Copyright © 2001–2016 JBoss by Red Hat. All rights reserved.