Package ghidra.formats.gfilesystem
Interface GFile
-
- All Known Implementing Classes:
GFileImpl,GFileLocal
public interface GFileRepresents a file in afilesystem.Only valid while the
owning filesystemobject is still open and notclosed.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description GFileSystemgetFilesystem()TheGFileSystemthat owns this file.FSRLgetFSRL()TheFSRLof this file.default longgetLastModified()longgetLength()Returns the length of this file, or -1 if not known.default java.util.List<GFile>getListing()Returns a listing of files in this sub-directory.java.lang.StringgetName()The name of this file.GFilegetParentFile()The parent directory of this file.java.lang.StringgetPath()The path and filename of this file, relative to its owning filesystem.booleanisDirectory()Returns true if this is a directory.
-
-
-
Method Detail
-
getFilesystem
GFileSystem getFilesystem()
TheGFileSystemthat owns this file.- Returns:
GFileSystemthat owns this file.
-
getParentFile
GFile getParentFile()
The parent directory of this file.- Returns:
- parent
GFiledirectory of this file.
-
getPath
java.lang.String getPath()
The path and filename of this file, relative to its owning filesystem.- Returns:
- path and filename of this file, relative to its owning filesystem.
-
getName
java.lang.String getName()
The name of this file.- Returns:
- name of this file.
-
isDirectory
boolean isDirectory()
Returns true if this is a directory.- Returns:
- boolean true if this file is a directory, false otherwise.
-
getLength
long getLength()
Returns the length of this file, or -1 if not known.- Returns:
- number of bytes in this file.
-
getLastModified
default long getLastModified()
-
-