Package org.jbpm.process.instance.command

## Class UpdateTimerCommand

- java.lang.Object
- - org.jbpm.process.instance.command.UpdateTimerCommand

- All Implemented Interfaces:
    `Serializable`, `org.kie.api.command.Command<Void>`, `org.kie.api.command.ExecutableCommand<Void>`, `org.kie.internal.command.ProcessInstanceIdCommand`
  Direct Known Subclasses:
    `RelativeUpdateTimerCommand`

      public class UpdateTimerCommand
      extends Object
      implements org.kie.api.command.ExecutableCommand<Void>, org.kie.internal.command.ProcessInstanceIdCommand

  See Also:
    Serialized Form

- - ### Field Summary

    Fields
    Modifier and Type | Field | Description
    --- | --- | ---
    `protected long` | `delay` |
    `protected long` | `period` |
    `protected long` | `processInstanceId` |
    `protected int` | `repeatLimit` |
    `protected long` | `timerId` |
    `protected String` | `timerName` |

  - ### Constructor Summary

    Constructors
    Constructor | Description
    --- | ---
    `UpdateTimerCommand​(long processInstanceId, long timerId, long delay)` |
    `UpdateTimerCommand​(long processInstanceId, long timerId, long period, int repeatLimit)` |
    `UpdateTimerCommand​(long processInstanceId, long timerId, long delay, long period, int repeatLimit)` |
    `UpdateTimerCommand​(long processInstanceId, String timerName, long delay)` |
    `UpdateTimerCommand​(long processInstanceId, String timerName, long period, int repeatLimit)` |
    `UpdateTimerCommand​(long processInstanceId, String timerName, long delay, long period, int repeatLimit)` |

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method | Description
    --- | --- | ---
    `protected long` | `calculateDelay​(long delay, TimerInstance timer)` |
    `Void` | `execute​(org.kie.api.runtime.Context context)` |
    `Long` | `getProcessInstanceId()` |
    `protected TimerManager` | `getTimerManager​(org.kie.api.runtime.KieSession ksession)` |
    `protected TimerInstance` | `rescheduleTimer​(TimerInstance timer, TimerManager tm)` |
    `void` | `setProcessInstanceId​(Long procInstId)` |
    `String` | `toString()` |

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

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

- - ### Field Detail

    - #### processInstanceId

          protected long processInstanceId

    - #### timerId

          protected long timerId

    - #### timerName

          protected String timerName

    - #### delay

          protected long delay

    - #### period

          protected long period

    - #### repeatLimit

          protected int repeatLimit

  - ### Constructor Detail

    - #### UpdateTimerCommand

          public UpdateTimerCommand​(long processInstanceId,
                                    String timerName,
                                    long delay)

    - #### UpdateTimerCommand

          public UpdateTimerCommand​(long processInstanceId,
                                    String timerName,
                                    long period,
                                    int repeatLimit)

    - #### UpdateTimerCommand

          public UpdateTimerCommand​(long processInstanceId,
                                    String timerName,
                                    long delay,
                                    long period,
                                    int repeatLimit)

    - #### UpdateTimerCommand

          public UpdateTimerCommand​(long processInstanceId,
                                    long timerId,
                                    long delay)

    - #### UpdateTimerCommand

          public UpdateTimerCommand​(long processInstanceId,
                                    long timerId,
                                    long period,
                                    int repeatLimit)

    - #### UpdateTimerCommand

          public UpdateTimerCommand​(long processInstanceId,
                                    long timerId,
                                    long delay,
                                    long period,
                                    int repeatLimit)

  - ### Method Detail

    - #### execute

          public Void execute​(org.kie.api.runtime.Context context)

      Specified by:
        `execute` in interface `org.kie.api.command.ExecutableCommand<Void>`

    - #### setProcessInstanceId

          public void setProcessInstanceId​(Long procInstId)

      Specified by:
        `setProcessInstanceId` in interface `org.kie.internal.command.ProcessInstanceIdCommand`

    - #### getProcessInstanceId

          public Long getProcessInstanceId()

      Specified by:
        `getProcessInstanceId` in interface `org.kie.internal.command.ProcessInstanceIdCommand`

    - #### getTimerManager

          protected TimerManager getTimerManager​(org.kie.api.runtime.KieSession ksession)

    - #### toString

          public String toString()

      Overrides:
        `toString` in class `Object`

    - #### calculateDelay

          protected long calculateDelay​(long delay,
                                        TimerInstance timer)

    - #### rescheduleTimer

          protected TimerInstance rescheduleTimer​(TimerInstance timer,
                                                  TimerManager tm)