com.webcodepro.applecommander.storage.filters
Class AppleWorksDataBaseFileFilter

java.lang.Object
  extended by com.webcodepro.applecommander.storage.filters.AppleWorksDataBaseFileFilter
All Implemented Interfaces:
FileFilter

public class AppleWorksDataBaseFileFilter
extends java.lang.Object
implements FileFilter

Export an AppleWorks database file to a text file. Current export is limited to a standard comma-separated file (CSV) file format which should be suitable to load into a database or a spreadsheet.

Data base files start with a variable length header, followed by 600 bytes for each report format (if any), the standard values record, then variable length information for each record. Note that the first data record contains the standard (presumably default) values. The category entries are in the same order that the category names appear in the header record.

See: http://www.gno.org/pub/apple2/doc/apple/filetypes/ftn.19.xxxx

Date Created: February 15, 2003

Author:
Rob Greene

Constructor Summary
AppleWorksDataBaseFileFilter()
          Create an AppleWorksDataBaseFileFilter.
 
Method Summary
protected  void convertDate(java.io.PrintWriter printWriter, java.lang.String date)
          Convert the date entry.
protected  void convertTime(java.io.PrintWriter printWriter, java.lang.String time)
          Convert the time entry.
 byte[] filter(FileEntry fileEntry)
          Process the given FileEntry and return a byte array with filtered data.
 java.lang.String getSuggestedFileName(FileEntry fileEntry)
          Give suggested file name.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AppleWorksDataBaseFileFilter

public AppleWorksDataBaseFileFilter()
Create an AppleWorksDataBaseFileFilter.

Method Detail

filter

public byte[] filter(FileEntry fileEntry)
Process the given FileEntry and return a byte array with filtered data.

Specified by:
filter in interface FileFilter
See Also:
FileFilter.filter(FileEntry)

getSuggestedFileName

public java.lang.String getSuggestedFileName(FileEntry fileEntry)
Give suggested file name.

Specified by:
getSuggestedFileName in interface FileFilter
See Also:
FileFilter.getSuggestedFileName(FileEntry)

convertDate

protected void convertDate(java.io.PrintWriter printWriter,
                           java.lang.String date)
Convert the date entry.


convertTime

protected void convertTime(java.io.PrintWriter printWriter,
                           java.lang.String time)
Convert the time entry.