Class EDataConnectorD
java.lang.Object
org.scictrl.mp.orbitcorrect.epics.EAbstractDataConnector<Double>
org.scictrl.mp.orbitcorrect.epics.EDataConnectorD
- All Implemented Interfaces:
IDataConnector<Double>
,IWriteConnector<Double>
public class EDataConnectorD
extends EAbstractDataConnector<Double>
implements IWriteConnector<Double>
EDataConnectorD class.
- Author:
- igor@scictrl.com
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.scictrl.mp.orbitcorrect.model.IDataConnector
IDataConnector.PushStrategy, IDataConnector.UpdateStrategy
-
Field Summary
Modifier and TypeFieldDescriptionprotected org.scictrl.csshell.epics.EPICSConnection
<Double> remote connection/.Fields inherited from class org.scictrl.mp.orbitcorrect.epics.EAbstractDataConnector
element, engine
-
Constructor Summary
ConstructorDescriptionEDataConnectorD
(EControlSystemEngine engine, IBindedElement<Double> element, org.scictrl.csshell.epics.EPICSConnection<Double> connection) Constructor for EDataConnectorD. -
Method Summary
Modifier and TypeMethodDescriptionvoid
destroy()
Destroys remote connection and release all relevant resources.get()
Gets value from remote data source and returns it.org.scictrl.csshell.epics.EPICSConnection
<Double> Getter for the fieldconnection
.getFormat.long
getLatestReceivedTimestamp.Returns latest position delivered to the connector by way of event updates.double
getMaxValue.double
getMinValue.getName()
getName.boolean
isReady()
A quick tests of connection and device by examining locally available data.void
set.boolean
test()
Tests connection and device if it is in usable state.Methods inherited from class org.scictrl.mp.orbitcorrect.epics.EAbstractDataConnector
dataType
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.scictrl.mp.orbitcorrect.model.IDataConnector
dataType
-
Field Details
-
connection
remote connection/.
-
-
Constructor Details
-
EDataConnectorD
public EDataConnectorD(EControlSystemEngine engine, IBindedElement<Double> element, org.scictrl.csshell.epics.EPICSConnection<Double> connection) throws Exception Constructor for EDataConnectorD.
- Parameters:
engine
- aEControlSystemEngine
objectelement
- aIBindedElement
objectconnection
- aEPICSConnection
object- Throws:
Exception
- if fails
-
-
Method Details
-
get
Gets value from remote data source and returns it.- Specified by:
get
in interfaceIDataConnector<Double>
- Returns:
- value from remote data source.
- Throws:
Exception
- if remote get fails
-
getLatestReceivedValue
Returns latest position delivered to the connector by way of event updates.- Specified by:
getLatestReceivedValue
in interfaceIDataConnector<Double>
- Returns:
- lates data update value
-
destroy
public void destroy()Destroys remote connection and release all relevant resources.- Specified by:
destroy
in interfaceIDataConnector<Double>
-
test
public boolean test()Tests connection and device if it is in usable state. This may include making remote calls and checking remote status or other values.- Specified by:
test
in interfaceIDataConnector<Double>
- Returns:
- true if connector can be used
-
isReady
public boolean isReady()A quick tests of connection and device by examining locally available data. It is suppose to be lightweight method, avoiding making remote calls and should exit quickly.- Specified by:
isReady
in interfaceIDataConnector<Double>
- Returns:
- true if connector can be used
-
getFormat
getFormat.
- Specified by:
getFormat
in interfaceIDataConnector<Double>
- Returns:
- a
String
object - Throws:
ControlSystemException
- if any.
-
getLatestReceivedTimestamp
public long getLatestReceivedTimestamp()getLatestReceivedTimestamp.
- Specified by:
getLatestReceivedTimestamp
in interfaceIDataConnector<Double>
- Returns:
- a long
-
getName
getName.
- Specified by:
getName
in interfaceIDataConnector<Double>
- Returns:
- a
String
object
-
getMaxValue
getMaxValue.
getMaxValue.
- Specified by:
getMaxValue
in interfaceIWriteConnector<Double>
- Returns:
- a double
- Throws:
ControlSystemException
- if any.
-
getMinValue
getMinValue.
getMinValue method comment.- Specified by:
getMinValue
in interfaceIWriteConnector<Double>
- Returns:
- a double
- Throws:
ControlSystemException
- if any.
-
set
set.
- Specified by:
set
in interfaceIWriteConnector<Double>
- Parameters:
d
- a T object- Throws:
ControlSystemException
- if any.
-
getConnection
Getter for the field
connection
.- Returns:
- a
EPICSConnection
object
-