Package globus.glmap

Class GLMapStorage

Direct Known Subclasses:
GLMapDocumentTreeStorage, GLMapFileStorage

public abstract class GLMapStorage extends GLNativeObject
Interface for storage of data
  • Method Details

    • registerForSQLite

      public boolean registerForSQLite(String vfsName)
      Register storage as VFS for SQLite
      Parameters:
      vfsName - name to register as VFS
      Returns:
      true if success
    • unregisterForSQLite

      public boolean unregisterForSQLite()
      Remove storage registration of SQLite
      Returns:
      true if success
    • getParent

      public abstract GLMapStorage getParent()
      Gets name of storage
      Returns:
      name of storage
    • getPath

      @Nullable public abstract String getPath()
      Gets the full path of this storage.
      Returns:
      the full path of this storage
    • getName

      public abstract String getName()
      Gets name of storage
      Returns:
      name of storage
    • listFiles

      public abstract GLMapStorageFile[] listFiles()
      List files in storage
      Returns:
      files in storage
    • findFile

      @Nullable public abstract GLMapStorageFile findFile(String name, boolean create)
      Searches file with given name
      Parameters:
      name - name of file
      create - create if missing
      Returns:
      file object or null if failed
    • findStorage

      @Nullable public abstract GLMapStorage findStorage(String name, boolean create)
      Opens new storage inside this storage (folder)
      Parameters:
      name - name of storage
      create - create if missing
      Returns:
      new storage
    • findStorageRecursive

      @Nullable public GLMapStorage findStorageRecursive(String path)
      Opens new storage with path
      Parameters:
      path - path inside storage. e.g. "a/b/c"
      Returns:
      new storage
    • getFreeSpace

      public abstract Long getFreeSpace()
      Returns free space in storage
      Returns:
      free space in storage or -1 if storage is unavailable.