Class ScanBean

All Implemented Interfaces:
Serializable

public final class ScanBean extends StatusBean
This bean is used to disseminate messages about what has happened to the scan while it is being written.

Do not extend this class to allow arbitrary information to be sent. The event encapsulated by this bean should be sending just the information defined here, metadata that cannot circumvent the nexus file.

For instance adding a dynamic set of information, a map perhaps, would allow information which should be saved in the Nexus file to circumvent the file and be set in the event. It was decided in various meetings that doing this could mean that some data is not recorded as it should be in nexus. Therefore these events are simply designed to contain events not data. They are not the same as the old ScanDataPoint system in GDA

See Also:
  • Field Details

  • Constructor Details

    • ScanBean

      public ScanBean()
    • ScanBean

      public ScanBean(ScanRequest req)
    • ScanBean

      public ScanBean(ScanBean scanBean)
  • Method Details

    • merge

      public <T extends IdBean> void merge(T with)
      Description copied from class: StatusBean
      Subclasses must override this method calling super.merge(...)
      Overrides:
      merge in class StatusBean
      Parameters:
      with -
    • getFilePath

      public String getFilePath()
    • setFilePath

      public void setFilePath(String filePath)
    • getScanNumber

      public int getScanNumber()
    • setScanNumber

      public void setScanNumber(int scanNumber)
    • getBeamline

      public String getBeamline()
    • setBeamline

      public void setBeamline(String beamline)
    • toString

      public String toString()
      Overrides:
      toString in class StatusBean
    • getExperimentId

      public String getExperimentId()
    • setExperimentId

      public void setExperimentId(String experimentId)
    • getPoint

      public int getPoint()
    • setPoint

      public void setPoint(int frame)
    • getSize

      public int getSize()
      NOTE the size is the approximate size of the scan by using the iterators. It is legal to do logic in an iterator - this means that the overall size is not constant for some custom scan types! However for the vast majority of linear scans size and shape are constant.
    • setSize

      public void setSize(int size)
      NOTE the size is the approximate size of the scan by using the iterators. It is legal to do logic in an iterator - this means that the overall size is not constant for some custom scan types! However for the vast majority of linear scans size and shape are constant.
      Parameters:
      size -
    • getPosition

      public IPosition getPosition()
    • setPosition

      public void setPosition(IPosition value)
    • putPosition

      public void putPosition(String name, int index, Object val)
    • scanStart

      public boolean scanStart()
      Returns:
      whether the scan has just started, i.e. transitioned from a Status.PREPARING state to a Status.RUNNING state.
    • scanEnd

      public boolean scanEnd()
      Returns:
      whether the scan has just ended, i.e. transitioned from a RUNNING/RESUMED state to a post-running state.
    • getScanRequest

      public ScanRequest getScanRequest()
    • setScanRequest

      public void setScanRequest(ScanRequest scanRequest)
    • getMappingBeanId

      public long getMappingBeanId()
    • setMappingBeanId

      public void setMappingBeanId(long id)
    • toProgressString

      public String toProgressString()
    • hashCode

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

      public boolean equals(Object obj)
      Overrides:
      equals in class StatusBean