Class Disks
java.lang.Object
com.webcodepro.applecommander.storage.Disks
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic DiskFactory.Context
Standardized FormattedDisk creation.static void
setFactories
(DiskFactory... factories) This call is a shim for the AntTask to populate its known factories since ServiceLoader doesn't appear to work within the Ant classpath.static int
sizeToFit
(long bytes) Find the standard sized disk that will fit the requested number of bytes.
-
Constructor Details
-
Disks
public Disks()
-
-
Method Details
-
setFactories
This call is a shim for the AntTask to populate its known factories since ServiceLoader doesn't appear to work within the Ant classpath. -
inspect
Standardized FormattedDisk creation. Uses the ServiceLoader mechanism to identify all potential FormattedDisk factories. -
sizeToFit
public static int sizeToFit(long bytes) Find the standard sized disk that will fit the requested number of bytes.- Returns:
- int size of the disk if it will satisfy the request, -1 otherwise
-