Class StorageHelper


  • public class StorageHelper
    extends Object
    Contains tools related to storage.
    • Method Detail

      • checkID

        public static void checkID​(String id)
        Checks that a storage ID is valid.
        Parameters:
        id - the storage ID to check.
        Throws:
        IllegalArgumentException - if the given storage identifier is not a valid identifier.
      • isValidID

        public static boolean isValidID​(String id)
        Checks whether a storage ID is valid or not.
        Parameters:
        id - the storage ID to check.
        Returns:
        true if the ID is valid, false otherwise.
      • checkOffset

        public static void checkOffset​(long offset)
        Checks that an offset is valid.
        Parameters:
        offset - the offset to check.
        Throws:
        IllegalArgumentException - if the given offset is negative.