dmolony-DiskBrowser/src/com/bytezone/diskbrowser/appleworks/CellAddress.java

27 lines
929 B
Java
Raw Permalink Normal View History

2015-06-01 09:35:51 +00:00
package com.bytezone.diskbrowser.appleworks;
import com.bytezone.diskbrowser.utilities.Utility;
2015-06-01 09:35:51 +00:00
2020-02-08 07:50:03 +00:00
// -----------------------------------------------------------------------------------//
class CellAddress
// -----------------------------------------------------------------------------------//
2015-06-01 09:35:51 +00:00
{
int colRef;
int rowRef;
2020-02-08 07:50:03 +00:00
// ---------------------------------------------------------------------------------//
CellAddress (byte[] buffer, int offset)
// ---------------------------------------------------------------------------------//
2015-06-01 09:35:51 +00:00
{
colRef = buffer[offset];
rowRef = Utility.getShort (buffer, offset + 1);
2015-06-01 09:35:51 +00:00
}
2020-02-08 07:50:03 +00:00
// ---------------------------------------------------------------------------------//
2015-06-01 09:35:51 +00:00
@Override
public String toString ()
2020-02-08 07:50:03 +00:00
// ---------------------------------------------------------------------------------//
2015-06-01 09:35:51 +00:00
{
return String.format ("[Row=%04d, Col=%04d]", rowRef, colRef);
}
}