Class AcousticScrollerFX
java.lang.Object
pamScrollSystem.AbstractPamScroller
pamViewFX.fxNodes.pamScrollers.AbstractPamScrollerFX
pamViewFX.fxNodes.pamScrollers.acousticScroller.AcousticScrollerFX
- All Implemented Interfaces:
 Serializable,DataTimeLimits
- Direct Known Subclasses:
 TDAcousticScroller
The acoustic scroll pane shows a summary of all the acoustic data available in a particular scroll period.
- Author:
 - Jamie Macaulay
 - See Also:
 
- 
Property Summary
PropertiesTypePropertyDescriptionjavafx.beans.property.BooleanPropertyjavafx.beans.property.BooleanPropertyThe property value for the scroll bar moving. - 
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionprotected classTask for loading datagram data. - 
Field Summary
FieldsModifier and TypeFieldDescriptionbooleanTrue if in viewer mode.List of range observersFields inherited from class pamScrollSystem.AbstractPamScroller
needsNotify, observers, pamMenuParts, playSpeeds, scrollerData, scrollManager, usedDataBlocks - 
Constructor Summary
ConstructorsConstructorDescriptionAcousticScrollerFX(String name, javafx.geometry.Orientation orientation, int stepSizeMillis, long defaultLoadTime, boolean hasMenu) Constructor for the acoustic scroller. - 
Method Summary
Modifier and TypeMethodDescriptionvoidaddAcousticScrollGraphics(AcousticScrollerGraphics rawScrollBarGraphics2) Add graphics to the scroll bar.voidaddNewPamData(PamDataUnit rawDataUnit) Add a new data unit to the scroll bar so it can be drawn on the background canvas.voidaddRangeObserver(VisibleRangeObserver timeRangeListener) Add a range observer.voidanotherScrollerMovedInner(long newValue) Another managed scroller moved it's positionprotected voidCancel all data loading task that might be in a que.Get all subscribed graphics.doublegetBinsPerPixel(float sampleratre) Get the number of bins per pixel.longintThe current index of graphics.The main pane holding the scroller nodes.javafx.scene.layout.PaneGet the navigation pane.javafx.scene.layout.PanegetNode()Get the node which contain all controls for scrolling system.longThe start time of the scroller in milliseconds.doubleGet the value in millis.longThis will be none for sliders, such as on the map.longGet ther visiblebooleanvoidlayoutScrollBarPane(javafx.geometry.Orientation orientation) Layout the control pane containing scroll bar and buttons to navigate in time.voidBegins redrawing data hello in the scroll bar.voidloadScrollerData(boolean newTasks) Begins redrawing data hello in the scroll bar.voidpauseDataload(boolean pause) Pause the datagram loading.voidrangesChanged(long setValue) Called when ranges have been changed and tells scroller to go to a particular absolute value.voidremoveAcousticScrollGraphics(AcousticScrollerGraphics rawScrollBarGraphics2) Remove graphics from the s roll bar.voidremoveRangeObserver(VisibleRangeObserver timeRangeListener) Remove a range observer.voidrepaint(long diff) Repaint the canvas.javafx.beans.property.BooleanPropertyjavafx.beans.property.BooleanPropertyThe property value for the scroll bar moving.voidsetBlockIncrement(long blockIncrement) voidsetCurrentGraphicsIndex(int currentIndex) Set current index of graphics.voidsetDataGramColors(StandardPlot2DColours dataGramColors) Set the acoustic scroller colours.voidsetOrientation(javafx.geometry.Orientation orientation) voidsetRangeMillis(long minimumMillis, long maximumMillis, boolean notify) Set the range of the currently loaded data and optionally notify other scrollers.voidsetSampleRate(float samplerate) Set the sample rate on the display.voidsetScrollerGraphics(int i) Set the index of the scroller graphics.voidsetScrollRectVisible(boolean b) Set the scroll bar rectangle visible or invisble.voidsetUnitIncrement(long unitIncrement) voidsetVisibleMillis(long visibleAmount) voidvalueSetMillis(long valueMillis) Called when a new position has been setMethods inherited from class pamViewFX.fxNodes.pamScrollers.AbstractPamScrollerFX
createNavigationPane, getOrientation, getPageBackwardButton, getPageForwardButton, getSettingsButton, isShowing, openTimeNavigationDialogAWT, openTimeNavigationDialogFXMethods inherited from class pamScrollSystem.AbstractPamScroller
addDataBlock, addMenuParts, addObserver, anotherScrollerMovedOuter, coupledScrollerChanged, coupleScroller, destroyScroller, getDefaultLoadtime, getMaximumMillis, getMinimumMillis, getNumUsedDataBlocks, getObservers, getPageStep, getPamMenuParts, getRangeMillis, getScrollerCoupling, getScrollerData, getScrollManager, getSpecialLoadTimes, getStepSizeMillis, getUsedDataBlock, getVisibleEnd, isDataBlockUsed, isInSpecialList, notifyRangeChange, notifyValueChange, pageBack, pageForward, playbackStarted, playbackStopped, playTimerAction, rangesChangedF, reLoad, removeAllDataBlocks, removeDataBlock, removeObserver, setDefaultLoadtime, setPageStep, setScrollerCoupling, setStepSizeMillis, setValueMillis, startPlayback, stopPlayback, toString, uncoupleScroller 
- 
Property Details
- 
scrollerChanging
public javafx.beans.property.BooleanProperty scrollerChangingProperty- See Also:
 
 - 
scrollMoving
public javafx.beans.property.BooleanProperty scrollMovingPropertyThe property value for the scroll bar moving. True if the scroll bar is moving.- See Also:
 
 
 - 
 - 
Field Details
- 
rangeObserver
List of range observers - 
isViewer
public boolean isViewerTrue if in viewer mode. 
 - 
 - 
Constructor Details
- 
AcousticScrollerFX
public AcousticScrollerFX(String name, javafx.geometry.Orientation orientation, int stepSizeMillis, long defaultLoadTime, boolean hasMenu) Constructor for the acoustic scroller.- Parameters:
 name- - the name of the scroller.orientation- - the orientation of the scroller.stepSizeMillis- - the step sizedefaultLoadTime- - default load timehasMenu- - has a menu.
 
 - 
 - 
Method Details
- 
cancelDataLoadTasks
protected void cancelDataLoadTasks()Cancel all data loading task that might be in a que. Don;t want these loading when we are in a new data range! - 
loadScrollerData
public void loadScrollerData()Begins redrawing data hello in the scroll bar. - 
loadScrollerData
public void loadScrollerData(boolean newTasks) Begins redrawing data hello in the scroll bar. - 
pauseDataload
public void pauseDataload(boolean pause) Pause the datagram loading.This is used to pause the data gram loading for example if a data block is being accessed somewhere else. If pauseDataload(true) is called afterwards then the datagrams will start loading from their previous position.
 - 
addAcousticScrollGraphics
Add graphics to the scroll bar. This handles drawing data units on the scroll bar's background canvas.- Parameters:
 rawScrollBarGraphics- - the scroll bar graphics class to add.
 - 
removeAcousticScrollGraphics
Remove graphics from the s roll bar. This handles drawing data units on the scroll bar's background canvas.- Parameters:
 rawScrollBarGraphics- - the scroll bar graphics class to remove.
 - 
setCurrentGraphicsIndex
public void setCurrentGraphicsIndex(int currentIndex) Set current index of graphics.- Parameters:
 the- current index of currentIndex
 - 
getCurrentGraphicsIndex
public int getCurrentGraphicsIndex()The current index of graphics.- Returns:
 - the current index of the graphics showing in the scroll bar.
 
 - 
getAcousticScrollGraphics
Get all subscribed graphics.- Returns:
 - subscribed graphics.
 
 - 
addNewPamData
Add a new data unit to the scroll bar so it can be drawn on the background canvas.- Parameters:
 rawDataUnit- - the raw data unit.
 - 
setScrollerGraphics
public void setScrollerGraphics(int i) Set the index of the scroller graphics. These graphics are shown in the scroller canvas.- Parameters:
 i- - the index of the acousticScrollerGraphics array.
 - 
repaint
public void repaint(long diff) Repaint the canvas.- Parameters:
 diff-
 - 
setSampleRate
public void setSampleRate(float samplerate) Set the sample rate on the display. - 
getBinsPerPixel
public double getBinsPerPixel(float sampleratre) Get the number of bins per pixel. This is calculated from the width of the tdGraph in pixels, the time the display represents and the sample rate of raw sound data.- Returns:
 - the number of bins per pixel.
 
 - 
layoutScrollBarPane
public void layoutScrollBarPane(javafx.geometry.Orientation orientation) Layout the control pane containing scroll bar and buttons to navigate in time.- Parameters:
 orientation- - orientation of the time scroller.
 - 
setOrientation
public void setOrientation(javafx.geometry.Orientation orientation)  - 
getNode
public javafx.scene.layout.Pane getNode()Description copied from class:AbstractPamScrollerFXGet the node which contain all controls for scrolling system.- Specified by:
 getNodein classAbstractPamScrollerFX- Returns:
 - the FX component to go into the GUI.
 
 - 
getMainPane
The main pane holding the scroller nodes.- Returns:
 - the main pane holding scroller nodes
 
 - 
setUnitIncrement
public void setUnitIncrement(long unitIncrement) - Overrides:
 setUnitIncrementin classAbstractPamScroller- Parameters:
 unitIncrement- the unitIncrement to set in millis
 - 
getVisibleMillis
public long getVisibleMillis()Get ther visible- Returns:
 - The visible amount of the display in milliseconds.
 
 - 
rangesChanged
public void rangesChanged(long setValue) Description copied from class:AbstractPamScrollerCalled when ranges have been changed and tells scroller to go to a particular absolute value.- Specified by:
 rangesChangedin classAbstractPamScroller- Parameters:
 setValue-
 - 
setRangeMillis
public void setRangeMillis(long minimumMillis, long maximumMillis, boolean notify) Description copied from class:AbstractPamScrollerSet the range of the currently loaded data and optionally notify other scrollers.- Overrides:
 setRangeMillisin classAbstractPamScroller- Parameters:
 minimumMillis- minimum time in millisecondsmaximumMillis- maximum time in millisecondsnotify- notify the rangesChanged function.
 - 
setBlockIncrement
public void setBlockIncrement(long blockIncrement) - Overrides:
 setBlockIncrementin classAbstractPamScroller- Parameters:
 blockIncrement- the blockIncrement to set in millis
 - 
getBlockIncrement
public long getBlockIncrement() - 
setVisibleMillis
public void setVisibleMillis(long visibleAmount) - Overrides:
 setVisibleMillisin classAbstractPamScroller- Parameters:
 visibleAmount- the visibleAmount to set in millis
 - 
getValueMillis
public long getValueMillis()Description copied from class:AbstractPamScrollerThe start time of the scroller in milliseconds. This is the current position of the scroller NOT the start time of loaded data.- Specified by:
 getValueMillisin classAbstractPamScroller- Returns:
 - the valueMillis
 
 - 
getValueMillisD
public double getValueMillisD()Get the value in millis.- Returns:
 - the value in millis as a double.
 
 - 
valueSetMillis
public void valueSetMillis(long valueMillis) Description copied from class:AbstractPamScrollerCalled when a new position has been set- Specified by:
 valueSetMillisin classAbstractPamScroller- Parameters:
 valueMillis- new scroll value in milliseconds
 - 
anotherScrollerMovedInner
public void anotherScrollerMovedInner(long newValue) Description copied from class:AbstractPamScrollerAnother managed scroller moved it's position- Specified by:
 anotherScrollerMovedInnerin classAbstractPamScroller- Parameters:
 newValue- new value in millis
 - 
addRangeObserver
Add a range observer.- Parameters:
 timeRangeListener- - a time range observer
 - 
removeRangeObserver
Remove a range observer.- Parameters:
 timeRangeListener- - a time range observer.
 - 
getScrollBarPane
- Returns:
 
 - 
getTimeAxis
 - 
setDataGramColors
Set the acoustic scroller colours. Also sets colours for all available datagrams.- Parameters:
 dataGramColors- - the colours to set;
 - 
scrollerChangingProperty
public javafx.beans.property.BooleanProperty scrollerChangingProperty()- Returns:
 - the isChanging property.
 - See Also:
 
 - 
scrollMovingProperty
public javafx.beans.property.BooleanProperty scrollMovingProperty()The property value for the scroll bar moving. True if the scroll bar is moving.- Returns:
 - the scroll bar dragging property.
 
 - 
isScrollerChanging
public boolean isScrollerChanging()- Returns:
 - true of the scroller is changing position or visible range
 
 - 
setScrollRectVisible
public void setScrollRectVisible(boolean b) Set the scroll bar rectangle visible or invisble.- Parameters:
 b- - true to set visible.
 - 
getVisibleAmount
public long getVisibleAmount()Description copied from class:AbstractPamScrollerThis will be none for sliders, such as on the map. For other scrollers it should be the same as the time displayed in to the navigaiton buttons of the scroller.- Specified by:
 getVisibleAmountin classAbstractPamScroller- Returns:
 - the visible display time in milliseconds.
 
 
 -