TimelineView Class
Template: timeline.html
Item Index
Methods
- animate
- calculateSelectionChartPage
- checkSliderSelection
- confirmSlidersSelection
- drawControlChart
- drawIntervalOnSelectionCanvas
- drawSelectionChart
- getEventColor
- getEventVerboseType
- getNumberOfEventsBetween
- initialize
- logarithmicSeekTime
- manageSelectionChartArrows
- miniArrowsManager
- nextEvent
- nextSelectionChart
- prevSelectionChart
- render
- scrollSelectionCanvas
- seek
- selectionChartPages
- stopAnimation
- updateControlCanvas
- updateCursorPosition
- updateSelectedEvent
- updateSelectionCanvas
- writeTimelineDate
- writeTimelineInfo
Methods
animate
()
This method starts the animation of the timeline. The animation of the timeline is a set of consecutive seek invocation.
calculateSelectionChartPage
-
An
This method returns the page of the given event.
Parameters:
-
An
Objectinstance of Event
Returns:
checkSliderSelection
()
This method checks and prevents inconsistent selection of the Control Timeline.
confirmSlidersSelection
()
This method is triggered when a user changes the selection on the Control Timeline.
drawControlChart
()
This method draws the Control Timeline
drawIntervalOnSelectionCanvas
()
This method draws on the Selection Timeline an interval selected on the Control Timeline
drawSelectionChart
()
This method draws the Selection Timeline
getEventColor
-
The
This method provides a color for each type of event.
Parameters:
-
The
Stringtype of an event
getEventVerboseType
-
The
This method provides a description for each type of event.
Parameters:
-
The
Stringtype of an event
getNumberOfEventsBetween
-
A
-
A
This method returns the number of events occurring between two unix timestamps.
Parameters:
-
A
Integerunix timestamp
-
A
Integerunix timestamp
Returns:
initialize
-
A
The initialization method of this object.
Parameters:
-
A
Mapmap of parameters
logarithmicSeekTime
-
A
This method is useful to calculate the duration for a seek operation with a logarithm approach.
Parameters:
-
A
Floattime interval
Returns:
manageSelectionChartArrows
()
This method manages the arrows useful to change the page of the Selection Timeline.
miniArrowsManager
()
This method manages the mini arrows. The mini arrows are the two green arrows that appear when the timeline sliders (selectors) disappear from the visible selection timeline.
nextEvent
-
An
-
If
This method returns the next event in the timeline.
Parameters:
-
An
Objectinstance of Instant
-
If
Booleanthis optional parameter is true then the next event will be the first of the next block
Returns:
nextSelectionChart
()
This method draws the next page of the Selection Timeline
prevSelectionChart
()
This method draws the previous page of the Selection Timeline
render
()
This method draws this module (eg. inject the DOM and elements).
scrollSelectionCanvas
-
An
This method auto-scrolls the Selection Canvas when the selected instant is represented close to a margin.
Parameters:
-
An
Objectinstance of Instant
seek
-
An
-
The
This method manages the animation of the time cursor along the timeline.
Parameters:
-
An
Objectinstance of Instant which will be the final position of the time cursor
-
The
Floatduration of the animation
selectionChartPages
()
Array
This method creates an array of events each of which is the first of the related page.
Returns:
stopAnimation
()
This method stops a seek process
updateControlCanvas
()
This method updates the representation of the Control Timeline
updateCursorPosition
()
This method is triggered when a user clicks on the Control Timeline in order to change the current instant
updateSelectedEvent
()
This method is triggered when a user clicks on the Selection Timeline in order to change the current event
updateSelectionCanvas
()
This method updates the representation of the Selection Timeline
writeTimelineDate
()
This method prints information about the position of the time cursor.
writeTimelineInfo
-
Information
This method prints information about the timeline.
Parameters:
-
Information
String