Package gda.device.monitor
Class MonitorBase
java.lang.Object
gda.factory.ConfigurableBase
gda.factory.FindableConfigurableBase
gda.device.DeviceBase
gda.device.scannable.ScannableBase
gda.device.monitor.MonitorBase
- All Implemented Interfaces:
Device,Monitor,Scannable,Configurable,Findable,gda.observable.IObservable
- Direct Known Subclasses:
AdcMonitor,BeamMonitor,DummyMonitor,EpicsBeamMonitor,EpicsMonitor,EtherCATSignal,IonChamberBeamMonitor,RemainingScanTimeEstimator
@ServiceInterface(Monitor.class)
public abstract class MonitorBase
extends ScannableBase
implements Monitor
Base class for objects which need to operate in scans, but which have no
control over the values returned by getPosition()
This base class is important to help to distinguish types of scannables, especially when storing or presenting data from scans.
-
Field Summary
Fields inherited from class gda.device.scannable.ScannableBase
__doc__, DEFAULT_INPUT_NAME, DEFAULT_OUTPUT_FORMAT, extraNames, inputNames, level, outputFormatFields inherited from class gda.device.DeviceBase
DEFAULT_PROTECTION_LEVEL_PROPERTYFields inherited from interface gda.device.Scannable
ATTR_NEXUS_CATEGORY, ATTR_NX_CLASS, DEFAULT_INPUT_NAME, VALUE_UNAVAILABLE -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidasynchronousMoveTo(Object position) If called with a position this triggers a delay.intreturns the number of elements in this monitor.getUnit()gets the physical unit of the monitor.booleanisBusy()Check if the Scannable is moving/operating.Methods inherited from class gda.device.scannable.ScannableBase
__call__, __call__, __doc__, __getitem__, __len__, __repr__, __str__, atCommandFailure, atLevelEnd, atLevelMoveStart, atLevelStart, atPointEnd, atPointStart, atScanEnd, atScanLineEnd, atScanLineStart, atScanStart, checkPositionValid, externalToInternal, getExtraNames, getInputNames, getLevel, getOutputFormat, getPosition, getScanMetadataAttribute, getScanMetadataAttributeNames, getScanMetadataAttributes, internalToExternal, isAt, moveTo, rawAsynchronousMoveTo, rawGetPosition, setExtraNames, setInputNames, setLevel, setOutputFormat, setScanMetadataAttribute, setScanMetadataAttributes, stop, throwExceptionIfInvalidTarget, toFormattedString, toString, validateScannable, valueUnavailableString, waitWhileBusy, waitWhileBusyMethods inherited from class gda.device.DeviceBase
addIObserver, close, deleteIObserver, deleteIObservers, getAttribute, getName, getProtectionLevel, isBeingObserved, isConfigureAtStartup, notifyIObservers, setAttribute, setConfigureAtStartup, setName, setProtectionLevelMethods inherited from class gda.factory.ConfigurableBase
configure, isConfigured, reconfigure, setConfiguredMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface gda.factory.Configurable
configure, isConfigureAtStartup, isConfigured, reconfigureMethods inherited from interface gda.device.Device
close, getAttribute, getProtectionLevel, setAttribute, setProtectionLevelMethods inherited from interface gda.observable.IObservable
addIObserver, deleteIObserver, deleteIObserversMethods inherited from interface gda.device.Scannable
atCommandFailure, atLevelEnd, atLevelMoveStart, atLevelStart, atPointEnd, atPointStart, atScanEnd, atScanLineEnd, atScanLineStart, atScanStart, checkPositionValid, getExtraNames, getInputNames, getLevel, getOutputFormat, getPosition, getScanMetadataAttribute, getScanMetadataAttributeNames, getScanMetadataAttributes, isAt, moveTo, setExtraNames, setInputNames, setLevel, setOutputFormat, setScanMetadataAttribute, setScanMetadataAttributes, stop, toFormattedString, waitWhileBusy
-
Constructor Details
-
MonitorBase
public MonitorBase()
-
-
Method Details
-
asynchronousMoveTo
If called with a position this triggers a delay. Very useful if the monitor is hooked up to something that calculates a running average, or that is not updated very often. Trigger a move/operation and return immediately. Implementations of this method should be non-blocking to allow concurrent motion; the isBusy method will be used to determine when the move has completed. Converts the external (user) position to an internal position and passes this to rawAsynchronousMoveTo.- Specified by:
asynchronousMoveToin interfaceScannable- Overrides:
asynchronousMoveToin classScannableBase- Parameters:
position- Position to move to should have an element for each input field.- Throws:
DeviceException- See Also:
-
isBusy
public boolean isBusy()Description copied from interface:ScannableCheck if the Scannable is moving/operating. -
getElementCount
Description copied from interface:Monitorreturns the number of elements in this monitor.- Specified by:
getElementCountin interfaceMonitor- Returns:
- int the element count
- Throws:
DeviceException
-
getUnit
Description copied from interface:Monitorgets the physical unit of the monitor.- Specified by:
getUnitin interfaceMonitor- Returns:
- String the physical unit
- Throws:
DeviceException
-