org.zmpp.vm
Class DefaultStoryFileHeader

java.lang.Object
  extended by org.zmpp.vm.DefaultStoryFileHeader
All Implemented Interfaces:
StoryFileHeader

public class DefaultStoryFileHeader
extends Object
implements StoryFileHeader

This is the default implementation of the StoryFileHeader interface.

Version:
1.0
Author:
Wei-ju Wu

Constructor Summary
DefaultStoryFileHeader(MemoryReadAccess memaccess)
          Constructor.
 
Method Summary
 int getAbbreviationsAddress()
          Returns the start address of the abbreviations section.
 int getChecksum()
          Returns the checksum for the story file.
 int getDictionaryAddress()
          Returns the dictionary's start address.
 int getFileLength()
          Returns this story file's length.
 int getFlags1()
          Returns the flags1 field.
 int getFlags2()
          Returns the flags2 field.
 int getGlobalsAddress()
          Returns the address of the global variables.
 int getHighMemAddress()
          Returns the high memory start address.
 int getInterpreter()
          Returns the interpreter number.
 int getInterpreterVersion()
          Returns the interpreter version.
 int getObjectTableAddress()
          Returns the object table's start address.
 int getProgramStart()
          Returns the program counter start address.
 int getRelease()
          Returns the release number.
 int getRevision()
          Returns the revision number.
 String getSerialNumber()
          Returns this game's serial number.
 int getStaticsAddress()
          Returns the static memory start address.
 int getVersion()
          Returns the story file version.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DefaultStoryFileHeader

public DefaultStoryFileHeader(MemoryReadAccess memaccess)
Constructor.

Parameters:
memaccess - a MemoryReadAccess object
Method Detail

getVersion

public int getVersion()
Returns the story file version.

Specified by:
getVersion in interface StoryFileHeader
Returns:
the story file version

getFlags1

public int getFlags1()
Returns the flags1 field.

Specified by:
getFlags1 in interface StoryFileHeader
Returns:
the flags1 field

getRelease

public int getRelease()
Returns the release number.

Specified by:
getRelease in interface StoryFileHeader
Returns:
the release number

getHighMemAddress

public int getHighMemAddress()
Returns the high memory start address.

Specified by:
getHighMemAddress in interface StoryFileHeader
Returns:
the start of the high memory

getProgramStart

public int getProgramStart()
Returns the program counter start address.

Specified by:
getProgramStart in interface StoryFileHeader
Returns:
the PC start address

getDictionaryAddress

public int getDictionaryAddress()
Returns the dictionary's start address.

Specified by:
getDictionaryAddress in interface StoryFileHeader
Returns:
the dictionary start address

getObjectTableAddress

public int getObjectTableAddress()
Returns the object table's start address.

Specified by:
getObjectTableAddress in interface StoryFileHeader
Returns:
the object table's start address

getGlobalsAddress

public int getGlobalsAddress()
Returns the address of the global variables.

Specified by:
getGlobalsAddress in interface StoryFileHeader
Returns:
the global variables section

getStaticsAddress

public int getStaticsAddress()
Returns the static memory start address.

Specified by:
getStaticsAddress in interface StoryFileHeader
Returns:
the start address of the static memory

getFlags2

public int getFlags2()
Returns the flags2 field.

Specified by:
getFlags2 in interface StoryFileHeader
Returns:
the flags2 field

getSerialNumber

public String getSerialNumber()
Returns this game's serial number.

Specified by:
getSerialNumber in interface StoryFileHeader
Returns:
the serial number

getAbbreviationsAddress

public int getAbbreviationsAddress()
Returns the start address of the abbreviations section.

Specified by:
getAbbreviationsAddress in interface StoryFileHeader
Returns:
the abbreviations start address

getFileLength

public int getFileLength()
Returns this story file's length.

Specified by:
getFileLength in interface StoryFileHeader
Returns:
the file length

getChecksum

public int getChecksum()
Returns the checksum for the story file.

Specified by:
getChecksum in interface StoryFileHeader
Returns:
the checksum

getInterpreter

public int getInterpreter()
Returns the interpreter number.

Specified by:
getInterpreter in interface StoryFileHeader
Returns:
the interpreter number

getInterpreterVersion

public int getInterpreterVersion()
Returns the interpreter version.

Specified by:
getInterpreterVersion in interface StoryFileHeader
Returns:
the interpreter version

getRevision

public int getRevision()
Returns the revision number.

Specified by:
getRevision in interface StoryFileHeader
Returns:
the revision number


Copyright © 2005 . All Rights Reserved.