Class ProdosOrder
java.lang.Object
com.webcodepro.applecommander.storage.physical.ImageOrder
com.webcodepro.applecommander.storage.physical.ProdosOrder
- All Implemented Interfaces:
HintProvider
Supports disk images stored in ProDOS physical order.
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final int[]
This table contains the block offset for a particular DOS sector.static final int[]
Defines the location within a block in which the DOS sector resides. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiongetName()
Return the name of this image order.boolean
boolean
Indicates that this device is block ordered.boolean
Indicates that this device is track and sector ordered.byte[]
readBlock
(int block) Read the block from the disk image.byte[]
readSector
(int track, int sector) Retrieve the specified sector.void
writeBlock
(int block, byte[] data) Write the block to the disk image.void
writeSector
(int track, int sector, byte[] bytes) Write the specified sector.Methods inherited from class com.webcodepro.applecommander.storage.physical.ImageOrder
format, getBlocksOnDevice, getPhysicalSize, getSectorsPerDisk, getSectorsPerTrack, getSource, getTracksPerDisk, isSizeApprox, readBytes, setSource, writeBytes
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.applecommander.hint.HintProvider
isAny
-
Field Details
-
blockInterleave
public static final int[] blockInterleaveThis table contains the block offset for a particular DOS sector. -
blockOffsets
public static final int[] blockOffsetsDefines the location within a block in which the DOS sector resides. (0 = 0-255 and 1 = 256-511.)
-
-
Constructor Details
-
ProdosOrder
Construct a ProdosOrder.
-
-
Method Details
-
isBlockDevice
public boolean isBlockDevice()Indicates that this device is block ordered.- Specified by:
isBlockDevice
in classImageOrder
-
isTrackAndSectorDevice
public boolean isTrackAndSectorDevice()Indicates that this device is track and sector ordered.- Specified by:
isTrackAndSectorDevice
in classImageOrder
-
readBlock
public byte[] readBlock(int block) Read the block from the disk image. Note: Defined in terms of reading sectors.- Specified by:
readBlock
in classImageOrder
-
writeBlock
public void writeBlock(int block, byte[] data) Write the block to the disk image. Note: Defined in terms of reading sectors.- Specified by:
writeBlock
in classImageOrder
-
readSector
Retrieve the specified sector.- Specified by:
readSector
in classImageOrder
- Throws:
IllegalArgumentException
-
writeSector
Write the specified sector.- Specified by:
writeSector
in classImageOrder
- Throws:
IllegalArgumentException
-
getName
Return the name of this image order.- Specified by:
getName
in classImageOrder
-
is
-