Class SectorUsage
java.lang.Object
org.applecommander.usage.DiskUsage
org.applecommander.usage.SectorUsage
- All Implemented Interfaces:
EventListener, ChangeListener<FileStore.FileStoreChangeEvent>, InformationProvider
Provides sector level usage information. Sectors are always the same size in all contexts,
so it is hard-coded.
-
Nested Class Summary
Nested ClassesNested classes/interfaces inherited from class DiskUsage
DiskUsage.UsageType -
Constructor Summary
ConstructorsConstructorDescriptionSectorUsage(TrackSectorDevice.Geometry geometry, Consumer<SectorUsage.UsagePopulator> usageFn) -
Method Summary
Modifier and TypeMethodDescriptionintintgetTotal()intgetUsage(int track, int sector) voidvoidsetUsage(int track, int sector, DiskUsage.UsageType usageType) voidWhen the state of an object has changed, this method is invoked on all listeners.Methods inherited from class DiskUsage
getBytesFree, getBytesUsed, getFree, getTotalBytes, getUsed, information
-
Constructor Details
-
SectorUsage
public SectorUsage(TrackSectorDevice.Geometry geometry, Consumer<SectorUsage.UsagePopulator> usageFn)
-
-
Method Details
-
getUsageCounts
- Specified by:
getUsageCountsin classDiskUsage
-
populateUsage
public void populateUsage() -
getUsage
-
setUsage
-
stateChanged
Description copied from interface:ChangeListenerWhen the state of an object has changed, this method is invoked on all listeners. Note that the baseEventObjecthas a source that needs to be cast to the proper interface. -
getTotal
-
getTracksOnDisk
public int getTracksOnDisk() -
getSectorsPerTrack
public int getSectorsPerTrack()
-