Package ghidra.formats.gfilesystem.factory

# Interface GFileSystemProbeBytesOnly

All Superinterfaces:
  `GFileSystemProbe`

public interface GFileSystemProbeBytesOnly extends GFileSystemProbe
A `GFileSystemProbe` interface for filesystems that can be detected using just a few bytes from the beginning of the containing file.

Filesystem probes of this type are given precedence when possible since they tend to be simpler and quicker.

- ## Field Summary

  Fields
  Modifier and Type
  Field
  Description
  `static final int`
  `MAX_BYTESREQUIRED`
  Maximum that any GFileSystemProbeBytesOnly is allowed to specify as its `getBytesRequired()`.

- ## Method Summary

  Modifier and Type
  Method
  Description
  `int`
  `getBytesRequired()`
  The minimum number of bytes needed to be supplied to the `probeStartBytes(FSRL, byte[])` method.
  `boolean`
  `probeStartBytes(FSRL containerFSRL, byte[] startBytes)`
  Probes the supplied `startBytes` byte[] array to determine if this filesystem implementation can handle the file.

- ## Field Details

  - ### MAX_BYTESREQUIRED

    static final int MAX_BYTESREQUIRED
    Maximum that any GFileSystemProbeBytesOnly is allowed to specify as its `getBytesRequired()`.
    See Also:
      - Constant Field Values

- ## Method Details

  - ### getBytesRequired

    int getBytesRequired()
    The minimum number of bytes needed to be supplied to the `probeStartBytes(FSRL, byte[])` method.
    Returns:
      min number of bytes needed for probe

  - ### probeStartBytes

    boolean probeStartBytes(FSRL containerFSRL, byte[] startBytes)
    Probes the supplied `startBytes` byte[] array to determine if this filesystem implementation can handle the file.
    Parameters:
      `containerFSRL` - the `FSRL` of the file containing the bytes being probed.
      `startBytes` - a byte array, with a length of at least `getBytesRequired()` containing bytes from the beginning (ie. offset 0) of the probed file.
    Returns:
      `true` if the specified file is handled by this filesystem implementation, `false` if not.