Class ThreadRecord

java.lang.Object
org.applecommander.shrinkit.ThreadRecord

public class ThreadRecord extends Object
This represents a single thread from the Shrinkit archive. As it is constructed, the thread "header" is read. Once all threads have been constructed, use readThreadData to load up the data.

Depending on the type of thread, the data may be text. If so, isText will return true and getText will return the string. Otherwise, the data should be read through one of the InputStream options.

  • Method Details

    • isText

      public boolean isText()
      Determine if this is a text-type field.
    • getText

      public String getText()
      Return the text data.
    • getBytes

      public byte[] getBytes()
      Get raw data bytes (compressed).
    • readThreadData

      public byte[] readThreadData() throws IOException
      Read all bytes from the record.
      Throws:
      IOException
    • getThreadClass

      public ThreadClass getThreadClass()
    • setThreadClass

      public void setThreadClass(ThreadClass threadClass)
    • getThreadFormat

      public ThreadFormat getThreadFormat()
    • setThreadFormat

      public void setThreadFormat(ThreadFormat threadFormat)
    • getThreadKind

      public ThreadKind getThreadKind()
    • setThreadKind

      public void setThreadKind(ThreadKind threadKind)
    • getThreadCrc

      public int getThreadCrc()
    • setThreadCrc

      public void setThreadCrc(int threadCrc)
    • getThreadEof

      public long getThreadEof()
    • setThreadEof

      public void setThreadEof(long threadEof)
    • getCompThreadEof

      public long getCompThreadEof()
    • setCompThreadEof

      public void setCompThreadEof(long compThreadEof)
    • getThreadData

      public byte[] getThreadData()
    • setThreadData

      public void setThreadData(byte[] threadData)