Class SingleScannableWriter

java.lang.Object
gda.data.scan.datawriter.scannablewriter.SingleScannableWriter
All Implemented Interfaces:
ScannableWriter
Direct Known Subclasses:
EnergyScannableWriter, TransformationWriter

public class SingleScannableWriter extends Object implements ScannableWriter
At the moment this class should handle well formed scannables returning Doubles or Strings with multiple input or extra names
  • Constructor Details

    • SingleScannableWriter

      public SingleScannableWriter()
  • Method Details

    • getComponentWriter

      protected ComponentWriter getComponentWriter(String componentName, Object object, int index)
    • resetComponentWriters

      protected void resetComponentWriters()
    • makeScannable

      public Collection<? extends SelfCreatingLink> makeScannable(NexusFile file, GroupNode group, Scannable s, Object position, int[] dim, boolean primary) throws NexusException
      Description copied from interface: ScannableWriter
      This is the call to generate the structure in the file If only
      Specified by:
      makeScannable in interface ScannableWriter
      Parameters:
      file - reference to the NeXusfile with the pointer being in the current NXentry
      s - the scannable to write
      position - the scannable data to write (do NOT call s.getPosition() to get it!)
      dim - number of dimensions in the scan (or {1} for metadata only)
      primary - Is this scannable primary, will add primary=1 attribute to the scannables dataset
      Throws:
      NexusException
    • writeScannable

      public void writeScannable(NexusFile file, GroupNode group, Scannable s, Object position, int[] start) throws NexusException
      Specified by:
      writeScannable in interface ScannableWriter
      Parameters:
      file -
      s -
      position -
      Throws:
      NexusException
    • getPaths

      public String[] getPaths()
    • setPaths

      public final void setPaths(String... paths)
    • getUnits

      public String[] getUnits()
    • setUnits

      public final void setUnits(String... units)
    • setPrerequisiteScannableNames

      public final void setPrerequisiteScannableNames(Collection<String> prerequisiteScannableNames)
    • getPrerequisiteScannableNames

      public Set<String> getPrerequisiteScannableNames()
      Description copied from interface: ScannableWriter
      Retrieve a set of other Scannables that need to have their position recorded in order for this Scannable position to be valid. This is mostly the case for motion dependencies, like in diffractometers where the location of an axis depends on other prior motors.
      Specified by:
      getPrerequisiteScannableNames in interface ScannableWriter
      Returns:
      set of prequisites scannable names, never null
    • getCwriter

      protected Map<String,ComponentWriter> getCwriter()