diff --git a/atrcopy.py b/atrcopy.py index 383bf62..dd5eba9 100755 --- a/atrcopy.py +++ b/atrcopy.py @@ -195,6 +195,12 @@ class ObjSegment(object): if self.error: s += " " + self.error return s + + def __len__(self): + return len(self.data) + + def __getitem__(self, val): + return self.data[val] class AtariDosFile(object): """Parse a binary chunk into segments according to the Atari DOS object