misim
Class FileHandler
java.lang.Object
|
+--misim.FileHandler
- public class FileHandler
- extends java.lang.Object
Constructor Summary |
FileHandler(boolean isApplet,
java.lang.String workingDir,
java.awt.Frame owner,
LogListener logging)
|
Method Summary |
boolean |
existsFile(java.lang.String name,
java.lang.String directory)
Test to see if a file exists |
TextFile |
findIncludeFile(java.lang.String name,
java.lang.String directory,
Parser aParser,
EditorPrefs prefs)
Search for the given include file. |
int |
loadBinary(Processor processor,
java.util.Vector binaryFiles,
java.awt.Point location)
|
TextFile |
promptToLoad(java.lang.String postfix,
java.lang.String title,
java.util.Vector options,
java.awt.Point location)
|
FileDetails |
promptToSave(java.lang.String saveas,
java.lang.String postfix,
java.lang.String title)
|
void |
saveBinary(Processor processor)
|
void |
setIncludeDir(java.lang.String includeDir)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
FileHandler
public FileHandler(boolean isApplet,
java.lang.String workingDir,
java.awt.Frame owner,
LogListener logging)
setIncludeDir
public void setIncludeDir(java.lang.String includeDir)
promptToLoad
public TextFile promptToLoad(java.lang.String postfix,
java.lang.String title,
java.util.Vector options,
java.awt.Point location)
throws java.io.FileNotFoundException,
java.io.IOException
promptToSave
public FileDetails promptToSave(java.lang.String saveas,
java.lang.String postfix,
java.lang.String title)
throws java.io.IOException
loadBinary
public int loadBinary(Processor processor,
java.util.Vector binaryFiles,
java.awt.Point location)
saveBinary
public void saveBinary(Processor processor)
findIncludeFile
public TextFile findIncludeFile(java.lang.String name,
java.lang.String directory,
Parser aParser,
EditorPrefs prefs)
throws java.io.IOException
- Search for the given include file. The directory for
the source file containing the include statement may
be specified, or left null. This is searched first, if not
null, then the working directory for the application is
checked, then the include directory, if that has been
specified.
The text file object is cached and (re)read as appropriate.
- Parameters:
name
- The name of the include file.directory
- The directory containing the current source file, or null- Returns:
- a text file representing the include file, or null if not found
existsFile
public boolean existsFile(java.lang.String name,
java.lang.String directory)
- Test to see if a file exists