Package x3

Class X3PBFileSystem

java.lang.Object
x3.X3FileSystem
x3.X3PBFileSystem

public class X3PBFileSystem
extends X3FileSystem
X3 file functions using the standards used for the Decimus system which is slightly different to the d3 standard.
Author:
Doug Gillespie
  • Constructor Details

  • Method Details

    • readFileHeader

      public java.lang.String readFileHeader​(java.io.DataInputStream dis) throws java.io.IOException
      Specified by:
      readFileHeader in class X3FileSystem
      Throws:
      java.io.IOException
    • decodeFileHeader

      public X3FileHeader decodeFileHeader​(java.lang.String xmlString)
      Description copied from class: X3FileSystem
      Called just after the first few bytes of the file have been read in order to identify the file type. All files should start with a valid header, so read it now.
      Specified by:
      decodeFileHeader in class X3FileSystem
      Returns:
      a valid file header structure, or null in the event of failure.
    • createX3HeaderXML

      public org.w3c.dom.Document createX3HeaderXML​(int blockLength, int sampleRate, int nChannels)
      Description copied from class: X3FileSystem
      Create an XML document with header information.
      Specified by:
      createX3HeaderXML in class X3FileSystem
      Parameters:
      blockLength - block length used throughout file
      sampleRate - sample rate
      nChannels - number o channels
      Returns:
      XML document to go at front of file.
    • readFrameHeader

      public X3FrameHeader readFrameHeader​(java.io.DataInputStream dis, X3FileHeader x3FileHeader, X3FrameHeader exHeader) throws java.io.IOException
      Description copied from class: X3FileSystem
      Read a frame header from the input stream.
      Specified by:
      readFrameHeader in class X3FileSystem
      Parameters:
      dis - data input stream
      x3FileHeader - file header so data can be extracted if format data is spread incorrectly between file and block headers .
      exHeader - Existing frame header which can be reused or will be created if null.
      Returns:
      a frame header structure.
      Throws:
      java.io.IOException