| 
 | |||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectorg.annotation.wordfreak.AnnotatedFileManager
Class that handles and disbatches file
 related events to AnnotatedFileListeners.  These events come from
 this object when it is their FileRequestListener and from the
 EventManager.
AnnotatedFileListener, 
FileRequestListener, 
EventManager| Constructor Summary | |
| AnnotatedFileManager() | |
| Method Summary | |
|  void | addAnnotatedFileListener(AnnotatedFileListener adl)Registers an AnnotatedFileListenerto be notified
 of file related changes. | 
|  void | addGold(java.lang.String filename)Adds the annotated file name/path specified by fileNameto the set of gold files. | 
|  boolean | allAnnotatedFilesSaved()Returns true is all annotated files have been saved, false otherwise. | 
|  boolean | closeAnnotatedFile(java.lang.String annFileName)Returns true if the the annotated file specified by annFileName could be closed. | 
|  boolean | eventTranspired(java.lang.String eventType,
                java.lang.Object source) | 
|  java.io.File | getAnnotatedFile(java.lang.String sourceFileName)Returns a likly annotated file for this source file name. | 
|  int | getFileCount()Returns the number of files which have been opened. | 
|  FileFormat | getFileFormat(javax.swing.filechooser.FileFilter ff)Returns the file format associated with the specified file filter. | 
|  FileFormat | getFileFormat(java.lang.String name)Returns the file format associated with the specified file format name. | 
|  FileFormat | getFileFormatForFile(java.lang.String fileName)Returns the file format associated with the specified file name. | 
|  java.util.Iterator | getFileFormatNames()Returns an iterator over the names of currently loaded file formats. | 
|  AnnotationFile | getFileFromPath(java.lang.String p)Returns the annotated file associated with the name/path of the file sent as a parameter. | 
|  void | incrementProgress() | 
|  void | incrementProgress(int v) | 
|  java.util.Iterator | iterator()Returns an iterator over the opened files. | 
|  boolean | openAnnotatedFile(java.lang.String annFileName)Returns true if the source file specified by fileName and its coresponding annotated file could be opened. | 
|  boolean | openAnnotatedFile(java.lang.String fileName,
                  java.lang.String annFileName)Returns true if the source file specified by fileName and the annotated file specified by annFileName could be opened.' | 
|  boolean | openAnnotatedFile(java.lang.String fileName,
                  java.lang.String annFileName,
                  AnnotatedFileFormat format) | 
|  boolean | openAnnotationGraphFile(java.lang.String signal,
                        java.lang.String fileName) | 
|  void | removeAnnotatedFileListener(AnnotatedFileListener adl)Un-registers an AnnotatedFileListener. | 
|  void | removeGold(java.lang.String filename)Removes the annotated file name/path specified by fileNamefrom the set of gold files. | 
| static boolean | saveAnnotatedFile(AnnotationFile f,
                  java.lang.String name) | 
|  boolean | saveAnnotatedFile(AnnotationFile af,
                  java.lang.String name,
                  java.awt.Component source) | 
|  boolean | saveAnnotatedFile(java.lang.String annFileName)Returns true if the the annotated file specified by annFileName could be saved. | 
| static boolean | saveTextFile(AnnotationFile f) | 
| static boolean | saveTextFile(AnnotationFile f,
             java.lang.String name) | 
|  boolean | scanAnnotatedFile(java.lang.String fileName,
                  java.lang.String annFileName)Returns true if the source file specified by fileName and the annotated file specified by annFileName could be scaned. | 
|  void | setAnnotatorNameListener(FilterCriteriaManager l) | 
|  java.lang.String[] | setFileFormat(java.lang.String file,
              AnnotatedFileFormat format)Assigns the annotated file specified by fileto the
 format specified byformatand returns the name of
 the annotated file and the source file. | 
|  void | setFileFormats(java.lang.String[] classes) | 
|  void | setFilter(AnnotationFilter f)Set the saving filter for all files. | 
|  void | setProgress(int v) | 
|  void | windowActivated(java.awt.event.WindowEvent e) | 
|  void | windowClosed(java.awt.event.WindowEvent e) | 
|  void | windowClosing(java.awt.event.WindowEvent e) | 
|  void | windowDeactivated(java.awt.event.WindowEvent e) | 
|  void | windowDeiconified(java.awt.event.WindowEvent e) | 
|  void | windowIconified(java.awt.event.WindowEvent e) | 
|  void | windowOpened(java.awt.event.WindowEvent e) | 
| Methods inherited from class java.lang.Object | 
| clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait | 
| Constructor Detail | 
public AnnotatedFileManager()
| Method Detail | 
public void setFileFormats(java.lang.String[] classes)
public boolean eventTranspired(java.lang.String eventType,
                               java.lang.Object source)
eventTranspired in interface EventListenerpublic void setFilter(AnnotationFilter f)
FileRequestListener
setFilter in interface FileRequestListenerf - the filter.public FileFormat getFileFormatForFile(java.lang.String fileName)
FileRequestListener
getFileFormatForFile in interface FileRequestListenerfileName - the nae of the file.
FileFormat object associated with the 
 fileName parameter, or null of no file format handles this type of file.public java.io.File getAnnotatedFile(java.lang.String sourceFileName)
FileRequestListener
getAnnotatedFile in interface FileRequestListenerpublic java.util.Iterator getFileFormatNames()
FileRequestListener
getFileFormatNames in interface FileRequestListenerpublic FileFormat getFileFormat(java.lang.String name)
FileRequestListener
getFileFormat in interface FileRequestListenername - the name of the file format.
public FileFormat getFileFormat(javax.swing.filechooser.FileFilter ff)
FileRequestListener
getFileFormat in interface FileRequestListenerff - the file filter.
FileFormat object associated with the 
 ff parameter.
public java.lang.String[] setFileFormat(java.lang.String file,
                                        AnnotatedFileFormat format)
FileRequestListenerfile to the
 format specified by format and returns the name of
 the annotated file and the source file.
setFileFormat in interface FileRequestListenerfile - the name of the source file.format - the format of the file.
public boolean scanAnnotatedFile(java.lang.String fileName,
                                 java.lang.String annFileName)
FileRequestListener
scanAnnotatedFile in interface FileRequestListenerfileName - the name/path of the source file to be opene.annFileName - the name/path of the annotated file to be opened.
public boolean openAnnotatedFile(java.lang.String annFileName)
FileRequestListener
openAnnotatedFile in interface FileRequestListenerannFileName - the name/path of the source file to be opened.
public boolean openAnnotatedFile(java.lang.String fileName,
                                 java.lang.String annFileName,
                                 AnnotatedFileFormat format)
public boolean openAnnotatedFile(java.lang.String fileName,
                                 java.lang.String annFileName)
FileRequestListener
openAnnotatedFile in interface FileRequestListenerfileName - the name/path of the source file to be opene.annFileName - the name/path of the annotated file to be opened.
public boolean openAnnotationGraphFile(java.lang.String signal,
                                       java.lang.String fileName)
public int getFileCount()
FileRequestListener
getFileCount in interface FileRequestListenerpublic java.util.Iterator iterator()
FileRequestListener
iterator in interface FileRequestListenerpublic void addAnnotatedFileListener(AnnotatedFileListener adl)
FileRequestListenerAnnotatedFileListener to be notified
 of file related changes.
addAnnotatedFileListener in interface FileRequestListeneradl - the annotated file listener.public void removeAnnotatedFileListener(AnnotatedFileListener adl)
FileRequestListenerAnnotatedFileListener.
removeAnnotatedFileListener in interface FileRequestListeneradl - the annotated file listener.public static boolean saveTextFile(AnnotationFile f)
public static boolean saveTextFile(AnnotationFile f,
                                   java.lang.String name)
public boolean saveAnnotatedFile(AnnotationFile af,
                                 java.lang.String name,
                                 java.awt.Component source)
public static boolean saveAnnotatedFile(AnnotationFile f,
                                        java.lang.String name)
public boolean saveAnnotatedFile(java.lang.String annFileName)
FileRequestListener
saveAnnotatedFile in interface FileRequestListenerannFileName - the name/path of the annotated file to be saved.
public boolean closeAnnotatedFile(java.lang.String annFileName)
FileRequestListener
closeAnnotatedFile in interface FileRequestListenerannFileName - the name/path of the annotated file to be closed.
public boolean allAnnotatedFilesSaved()
FileRequestListener
allAnnotatedFilesSaved in interface FileRequestListenerpublic AnnotationFile getFileFromPath(java.lang.String p)
FileRequestListener
getFileFromPath in interface FileRequestListenerp - the file name/path.
p.public void setProgress(int v)
setProgress in interface ProgressListenerpublic void incrementProgress()
incrementProgress in interface ProgressListenerpublic void incrementProgress(int v)
incrementProgress in interface ProgressListenerpublic void windowOpened(java.awt.event.WindowEvent e)
windowOpened in interface java.awt.event.WindowListenerpublic void windowClosing(java.awt.event.WindowEvent e)
windowClosing in interface java.awt.event.WindowListenerpublic void windowClosed(java.awt.event.WindowEvent e)
windowClosed in interface java.awt.event.WindowListenerpublic void windowIconified(java.awt.event.WindowEvent e)
windowIconified in interface java.awt.event.WindowListenerpublic void windowDeiconified(java.awt.event.WindowEvent e)
windowDeiconified in interface java.awt.event.WindowListenerpublic void windowActivated(java.awt.event.WindowEvent e)
windowActivated in interface java.awt.event.WindowListenerpublic void windowDeactivated(java.awt.event.WindowEvent e)
windowDeactivated in interface java.awt.event.WindowListenerpublic void setAnnotatorNameListener(FilterCriteriaManager l)
public void addGold(java.lang.String filename)
FileRequestListenerfileName to the set of gold files.
addGold in interface FileRequestListenerfilename - the name/path of the annotated file.public void removeGold(java.lang.String filename)
FileRequestListenerfileName from the set of gold files.
removeGold in interface FileRequestListenerfilename - the name/path of the annotated file.| 
 | |||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||