org.openide.filesystems
Class FileStatusEvent

java.lang.Object
  |
  +--java.util.EventObject
        |
        +--org.openide.filesystems.FileStatusEvent
All Implemented Interfaces:
Serializable

public final class FileStatusEvent
extends EventObject

Event describing a change in annotation of files.

See Also:
Serialized Form

Fields inherited from class java.util.EventObject
source
 
Constructor Summary
FileStatusEvent(FileSystem fs, boolean icon, boolean name)
          Creates new FileStatusEvent.
FileStatusEvent(FileSystem fs, FileObject file, boolean icon, boolean name)
          Creates new FileStatusEvent
FileStatusEvent(FileSystem fs, Set files, boolean icon, boolean name)
          Creates new FileStatusEvent
 
Method Summary
 FileSystem getFileSystem()
          Getter for file system that caused the change.
 boolean hasChanged(FileObject file)
          Check whether the given file has been changed.
 boolean isIconChange()
          Do the files changed their icons?
 boolean isNameChange()
          Is the change change of name?
 
Methods inherited from class java.util.EventObject
getSource, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

FileStatusEvent

public FileStatusEvent(FileSystem fs,
                       Set files,
                       boolean icon,
                       boolean name)
Creates new FileStatusEvent
Parameters:
fs - file system that causes the event
files - set of FileObjects that has been changed
icon - has icon changed?
name - has name changed?

FileStatusEvent

public FileStatusEvent(FileSystem fs,
                       FileObject file,
                       boolean icon,
                       boolean name)
Creates new FileStatusEvent
Parameters:
fs - file system that causes the event
file - file object that has been changed
icon - has icon changed?
name - has name changed?

FileStatusEvent

public FileStatusEvent(FileSystem fs,
                       boolean icon,
                       boolean name)
Creates new FileStatusEvent. This does not specify the file that changed annotation, assuming that everyone should update its annotation. Please notice that this can be time consuming and should be fired only when really necessary.
Parameters:
fs - file system that causes the event
icon - has icon changed?
name - has name changed?
Method Detail

getFileSystem

public FileSystem getFileSystem()
Getter for file system that caused the change.
Returns:
file system

isNameChange

public boolean isNameChange()
Is the change change of name?

isIconChange

public boolean isIconChange()
Do the files changed their icons?

hasChanged

public boolean hasChanged(FileObject file)
Check whether the given file has been changed.
Parameters:
file - file to check
Returns:
true if the file has been affected by the change


Built on December 12 2001.  |  Portions Copyright 1997-2001 Sun Microsystems, Inc. All rights reserved.