Package nom.tam.fits

Class NullData

All Implemented Interfaces:
FitsElement

public final class NullData extends ImageData
A subclass of Data containing no actual data. It wraps an underlying data of null.
Since:
1.18
Author:
Attila Kovacs
See Also:
  • Constructor Details

    • NullData

      public NullData()
  • Method Details

    • read

      public void read(ArrayDataInput in)
      Description copied from class: Data

      Reads the data or skips over it for reading later, depending on whether reading from a stream or a random acessible input, respectively.

      In case the argument is a an instance of RandomAccess input (such as a FitsFile, the call will simply note where in the file the data segment can be found for reading at a later point, only when the data content is accessed. This 'deferred' reading behavior make it possible to process large HDUs even with small amount of RAM, and can result in a significant performance boost when inspectring large FITS files, or using only select content from large FITS files.

      Specified by:
      read in interface FitsElement
      Overrides:
      read in class ImageData
      Parameters:
      in - The input data stream
      See Also:
    • write

      public void write(ArrayDataOutput o)
      Description copied from interface: FitsElement
      Writes the contents of the element to a data sink, adding padding as necessary if the element (such as a header or data segment) is expected to complete the FITS block of 2880 bytes.
      Specified by:
      write in interface FitsElement
      Overrides:
      write in class ImageData
      Parameters:
      o - The data sink.
    • setBuffer

      public void setBuffer(Buffer data)
      Description copied from class: ImageData
      Sets the buffer that may hold a serialized version of the data for this image.
      Overrides:
      setBuffer in class ImageData
      Parameters:
      data - the buffer that may hold this image's data in serialized form.