Package drivers.nxfa

Class SfaDriver

All Implemented Interfaces:
DeviceDriver

public class SfaDriver extends XfaDriver
The SMSQE File Access device driver class that allows SMSQE access to SMSQE type files (with header) on a native drive. It implements 8 "drives" (SFA1_ to SFA8_) which point to native dirs.

The driver maintains header files for SMSQE files, which are saved with the files.

The driver opens XFAFiles,one for each SMSQE file. Each XfaFile gets a unique number (integer 0 - 0xffff) which gets put into the SMSQE channel definition block (offset 0x1E). For each drive, the driver maintains a HashMap ‹Integer,NfaFile› so that it can find the NfaFile with the integer.

See Also:
  • Constructor Details

    • SfaDriver

      public SfaDriver(boolean useXTcc)
      Creates the device driver.
      Parameters:
      useXTcc - if True, executable files are saved as XTcc files
  • Method Details

    • readHeaderOK

      public static int readHeaderOK(File f, MC68000Cpu cpu, ByteBuffer tempHeader)
      Tries to get a header for an SFA file and possibly copy it somewhere to memory.
      Parameters:
      f - the file in question.
      cpu - the smsqmulator.cpu.MC68000Cpu used.
      tempHeader - a ByteBuffer to read the header to from the file. If this is null or of insufficent size, one will be created on the fly.
      Returns:
      an int which can have the following values:
      • 0 = this file is not an SFA file
      • 1 = this file is an SFA file
      • -1 = this file is a directory
    • getNativeNames

      public String[] getNativeNames()
      Gets the names of the native qxl.win type files.
      Returns: