Class Blockette

java.lang.Object
edu.sc.seis.seisFile.mseed.Blockette
Direct Known Subclasses:
BlocketteUnknown, ControlBlockette, DataBlockette

public abstract class Blockette
extends java.lang.Object
Superclass of all seed blockettes. The actual blockettes do not store either their blockette type or their length in the case of ascii blockettes or next blockettes offset in the case of data blockettes as these are either already known (ie type) or may change after reading due to data changes. Instead each of these values are calculated based on the data.
  • Constructor Summary

    Constructors
    Constructor Description
    Blockette()  
  • Method Summary

    Modifier and Type Method Description
    abstract java.lang.String getName()  
    abstract int getSize()  
    abstract int getType()  
    abstract byte[] toBytes()  
    java.lang.String toString()  
    abstract void writeASCII​(java.io.PrintWriter out)
    Writes an ASCII version of the blockette.
    void writeASCII​(java.io.PrintWriter out, java.lang.String indent)  

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
  • Constructor Details

    • Blockette

      public Blockette()
  • Method Details

    • writeASCII

      public abstract void writeASCII​(java.io.PrintWriter out)
      Writes an ASCII version of the blockette. This is not meant to be a definitive ascii representation, merely to give something to print for debugging purposes. Ideally each field of each blockette should be printed in the order they appear in the blockette in a visually appealing way.
      Parameters:
      out - a Writer
    • writeASCII

      public void writeASCII​(java.io.PrintWriter out, java.lang.String indent)
    • getType

      public abstract int getType()
    • getName

      public abstract java.lang.String getName()
    • getSize

      public abstract int getSize()
    • toBytes

      public abstract byte[] toBytes()
    • toString

      public java.lang.String toString()
      Overrides:
      toString in class java.lang.Object