Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## evalplayer
Class TimeSlider

    java.lang.Object
      evalplayer.TimeSlider

All Implemented Interfaces:
  java.util.EventListener, javax.swing.event.ChangeListener

    public class TimeSlider

extends java.lang.Object
implements javax.swing.event.ChangeListener

Handles the functionality to jump to any time in an animation/exercise.

Author:
  Markus Krebs

Field Summary
`SimpleOperation` | `opProcessing`

Constructor Summary
`TimeSlider(PlayerExercise exercise)` Creates a new TimeSlider

Method Summary
`void` | `checkAndSendOperationExecutedMessage()` Checks and perform an eventually needed OPERATION_EXECUTED-Message.
`void` | `configure()` Configurates the time-slider with the current values of the actual exercise.
`static TimeSlider` | `getInstance()` Returns an actual instance of TimeSlider
`javax.swing.JPanel` | `getPanel()` Returns a panel that contains a slider to control the time.
`long` | `getTime()` Returns the current time-position
`void` | `setTime(long t)` Jump to a specified time
`void` | `stateChanged(javax.swing.event.ChangeEvent e)`

Methods inherited from class java.lang.Object
`equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### opProcessing

    public SimpleOperation opProcessing

Constructor Detail

### TimeSlider

    public TimeSlider(PlayerExercise exercise)

  Creates a new TimeSlider

  Parameters:
    `exercise` - The current exercise

Method Detail

### stateChanged

    public void stateChanged(javax.swing.event.ChangeEvent e)

  Specified by:
    `stateChanged` in interface `javax.swing.event.ChangeListener`

### getPanel

    public javax.swing.JPanel getPanel()

  Returns a panel that contains a slider to control the time.

  Returns:
    A panel containing a slider

### configure

    public void configure()

  Configurates the time-slider with the current values of the actual exercise. E.g. labels were created, that represent the start-time-stamps of each operation.
  This method should be called, when an other exercise was loaded.

### setTime

    public void setTime(long t)

  Jump to a specified time

  Parameters:
    `t` - time in milliseconds

### getTime

    public long getTime()

  Returns the current time-position

  Returns:
    time in milliseconds

### checkAndSendOperationExecutedMessage

    public void checkAndSendOperationExecutedMessage()

  Checks and perform an eventually needed OPERATION_EXECUTED-Message. This means if actually a START_OF_EXECUTION-Message was sended, then an OPERATION_EXECUTED -Message must follow!

### getInstance

    public static TimeSlider getInstance()

  Returns an actual instance of TimeSlider

  Returns:
    TimeSlider-Instance

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD