Package ghidra.formats.gfilesystem.factory

# Class FileSystemInfoRec

java.lang.Object
ghidra.formats.gfilesystem.factory.FileSystemInfoRec

public class FileSystemInfoRec extends Object
Holds information read from a `FileSystemInfo` annotation.

- ## Field Summary

  Fields
  Modifier and Type
  Field
  Description
  `static final Comparator<FileSystemInfoRec>`
  `BY_PRIORITY`
  A static `Comparator` that will order `FileSystemInfoRec` by their `priority`, with the highest priority elements sorted to the beginning of the list.

- ## Method Summary

  Modifier and Type
  Method
  Description
  `static FileSystemInfoRec`
  `fromClass(Class<? extends GFileSystem> fsClazz)`
  Instantiate a new `FileSystemInfoRec` from the information found in the `FileSystemInfo` annotation attached to the specified Class.
  `String`
  `getDescription()`
  Filesystem description, ie.
  `GFileSystemFactory<?>`
  `getFactory()`
  The `GFileSystemFactory` instance that will create new filesystem instances when needed.
  `Class<? extends GFileSystem>`
  `getFSClass()`
  The `Class` of the filesystem implementation.
  `int`
  `getPriority()`
  Filesystem relative priority.
  `String`
  `getType()`
  Filesystem 'type', ie.

  ### Methods inherited from class java.lang.Object

  `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- ## Field Details

  - ### BY_PRIORITY

    public static final Comparator<FileSystemInfoRec> BY_PRIORITY
    A static `Comparator` that will order `FileSystemInfoRec` by their `priority`, with the highest priority elements sorted to the beginning of the list.

- ## Method Details

  - ### fromClass

    public static FileSystemInfoRec fromClass(Class<? extends GFileSystem> fsClazz)
    Instantiate a new `FileSystemInfoRec` from the information found in the `FileSystemInfo` annotation attached to the specified Class.
    Parameters:
      `fsClazz` - class to query for file system info.
    Returns:
      new `FileSystemInfoRec`, or null if the class doesn't have valid file system meta data.

  - ### getType

    public String getType()
    Filesystem 'type', ie. "file", or "zip", etc.
    Returns:
      type string

  - ### getDescription

    public String getDescription()
    Filesystem description, ie. "XYZ Vendor Filesystem Type 1"
    Returns:
      description string

  - ### getPriority

    public int getPriority()
    Filesystem relative priority.

    See `FileSystemInfo.priority()`.

    Returns:
      priority int

  - ### getFSClass

    public Class<? extends GFileSystem> getFSClass()
    The `Class` of the filesystem implementation.
    Returns:
      `GFileSystem` derived class.

  - ### getFactory

    public GFileSystemFactory<?> getFactory()
    The `GFileSystemFactory` instance that will create new filesystem instances when needed.
    Returns:
      `GFileSystemFactory` for this filesystem