Class RunnableDeviceFinder<Model>

java.lang.Object
gda.factory.FindableBase
uk.ac.diamond.daq.detectors.addetector.RunnableDeviceFinder<Model>
Type Parameters:
Model -
All Implemented Interfaces:
Findable

public class RunnableDeviceFinder<Model> extends FindableBase
This class can be used to get a reference to an instance of a RunnableDevice from Jython.

RunnableDevices use the 'name' property to store the name of the device to be run, while the finder requires the 'name' property to contain the name of the object, so we cannot apply the Finder interface to a RunnableDevice.

Example XML (@see AreaDetectorRunnableDeviceProxy):


<bean id="pe1AreaDetectorRunnableDeviceProxy" class="uk.ac.diamond.daq.detectors.addetector.AreaDetectorRunnableDeviceProxy">
	<property name="name"        value="pe1AD"/>
</bean>

<bean id="pe1AreaDetectorRunnableDeviceProxyFinder" class="uk.ac.diamond.daq.detectors.addetector.RunnableDeviceFinder">
	<property name="name"        	value="pe1AreaDetectorRunnableDeviceProxyFinder"/>
	<property name="runnableDevice"	ref="pe1AreaDetectorRunnableDeviceProxy"/>
</bean>
Example Jython
pe1AreaDetectorRunnableDeviceProxyFinder = finder.find("pe1AreaDetectorRunnableDeviceProxyFinder")
pe1AreaDetectorRunnableDeviceProxy = pe1AreaDetectorRunnableDeviceProxyFinder.getRunnableDevice()
pe1AreaDetectorRunnableDeviceProxy.setRunnableDevice(pe1JythonAreaDetectorRunnableDevice)
  • Constructor Details

    • RunnableDeviceFinder

      public RunnableDeviceFinder()
  • Method Details

    • getRunnableDevice

      public IRunnableEventDevice<Model> getRunnableDevice()
      Returns:
      Returns the runnableDevice.
    • setRunnableDevice

      public void setRunnableDevice(IRunnableEventDevice<Model> runnableDevice)
      Parameters:
      runnableDevice - The runnableDevice to set.