Class AbstractNameableTimeoutable

java.lang.Object
org.eclipse.scanning.api.AbstractNameable
org.eclipse.scanning.api.AbstractNameableTimeoutable
All Implemented Interfaces:
INameable, ITimeoutable
Direct Known Subclasses:
AbstractDetectorModel, AbstractScannable, GenericModel

public abstract class AbstractNameableTimeoutable extends AbstractNameable implements ITimeoutable
Default implementations of functions in INameable and ITimeoutable

These implementations should be adequate for most classes.

Since:
GDA 9.20
  • Constructor Details

    • AbstractNameableTimeoutable

      public AbstractNameableTimeoutable()
  • Method Details

    • getTimeout

      public long getTimeout()
      Description copied from interface: ITimeoutable
      This is the timeout time in seconds which defaults to -1 If set the default timeout for an action on a device will use this value. For instance for detectors the run and write time will timeout if this field is set>0 or 10 seconds if none of the detector models have this field set. For scannables the IScannable interface extends this interface. If any motor at a given level implements this timeout, this time out (or the max of all the timeouts) will be used. If none are set the default is three minutes.
      Specified by:
      getTimeout in interface ITimeoutable
      Returns:
    • setTimeout

      public void setTimeout(long timeout)
      Specified by:
      setTimeout in interface ITimeoutable
      Parameters:
      timeout - in seconds
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class AbstractNameable
    • equals

      public boolean equals(Object obj)
      Overrides:
      equals in class AbstractNameable
    • toString

      public String toString()
      Overrides:
      toString in class AbstractNameable