Class CoffArchiveMemberHeader

java.lang.Object
ghidra.app.util.bin.format.coff.archive.CoffArchiveMemberHeader
All Implemented Interfaces:
StructConverter

public class CoffArchiveMemberHeader extends Object implements StructConverter
  • Field Details Link icon

  • Constructor Details Link icon

    • CoffArchiveMemberHeader Link icon

      public CoffArchiveMemberHeader(String name, long date, String userId, String groupId, String mode, long size, long payloadOffset, long memberOffset)
  • Method Details Link icon

    • read Link icon

      public static CoffArchiveMemberHeader read(BinaryReader reader, LongNamesMember longNames) throws IOException
      Reads a COFF archive member header from the specified reader, leaving the file position at the start of the this member's payload.

      The archive member's name is fixed up using the specified longNames object.

      Parameters:
      reader - stream from which to read the COFF archive member header from
      longNames - optional, string table with long file names (only present in some COFF ar formats)
      Returns:
      a new CoffArchiveMemberHeader
      Throws:
      IOException
    • getName Link icon

      public String getName()
    • getDate Link icon

      public long getDate()
      Milliseconds since java Date epoch
      Returns:
    • getUserId Link icon

      public String getUserId()
    • getGroupId Link icon

      public String getGroupId()
    • getUserIdInt Link icon

      public int getUserIdInt()
    • getGroupIdInt Link icon

      public int getGroupIdInt()
    • getMode Link icon

      public String getMode()
    • getSize Link icon

      public long getSize()
    • getPayloadOffset Link icon

      public long getPayloadOffset()
    • getFileOffset Link icon

      public long getFileOffset()
    • isCOFF Link icon

      public boolean isCOFF()
      Returns true if this header contains a COFF file.
      Returns:
      true if this header contains a COFF file
    • toDataType Link icon

      public DataType toDataType() throws DuplicateNameException, IOException
      Description copied from interface: StructConverter
      Returns a structure datatype representing the contents of the implementor of this interface.

      For example, given:

       class A {
           int foo;
           double bar;
       }
       

      The return value should be a structure data type with two data type components; an INT and a DOUBLE. The structure should contain field names and, if possible, field comments.

      Specified by:
      toDataType in interface StructConverter
      Returns:
      returns a structure datatype representing the implementor of this interface
      Throws:
      DuplicateNameException - when a datatype of the same name already exists
      IOException - if an IO-related error occurs
      See Also: