Class SectionHeaderBlock


  • public class SectionHeaderBlock
    extends java.lang.Object
    Section header block starts the pcapng files and contains sections.
    • Constructor Summary

      Constructors 
      Constructor Description
      SectionHeaderBlock​(boolean bigEndian, int major, int minor, int sectionLength)
      Creates a section header block with a given values.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      boolean isBigEndian()
      Returns the information on endiannes of this section.
      boolean isLittleEndian()
      Returns the information on endiannes of this section.
      int majorVersion()
      Major version of the PCAPNG format used.
      int minorVersion()
      Minor version of the PCAPNG format used.
      java.lang.String toString()  
      • Methods inherited from class java.lang.Object

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

      • SectionHeaderBlock

        public SectionHeaderBlock​(boolean bigEndian,
                                  int major,
                                  int minor,
                                  int sectionLength)
        Creates a section header block with a given values.
        Parameters:
        bigEndian - If true, then this section is big endian.
        major - Major version of the PCAPNG format used.
        minor - Minor version of a PCAPNG format used.
        sectionLength - Length of a section, in bytes. May be -1, "indicating unspecified".
    • Method Detail

      • toString

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

        public int majorVersion()
        Major version of the PCAPNG format used.
        Returns:
        major version
      • minorVersion

        public int minorVersion()
        Minor version of the PCAPNG format used.
        Returns:
        minor version
      • isBigEndian

        public boolean isBigEndian()
        Returns the information on endiannes of this section.
        Returns:
        true, if this section is big endian, false if little-endian
      • isLittleEndian

        public boolean isLittleEndian()
        Returns the information on endiannes of this section.
        Returns:
        true, if this section is little endian, false if big endian