com.teamdev.filewatch
Class FileEvent.Renamed

java.lang.Object
  extended by java.util.EventObject
      extended by com.teamdev.filewatch.FileEvent
          extended by com.teamdev.filewatch.FileEvent.Renamed
All Implemented Interfaces:
java.io.Serializable
Direct Known Subclasses:
FileEvent.Moved
Enclosing class:
FileEvent

public static class FileEvent.Renamed
extends FileEvent

The event for a renamed file.

See Also:
Serialized Form

Nested Class Summary
 
Nested classes/interfaces inherited from class com.teamdev.filewatch.FileEvent
FileEvent.Added, FileEvent.Changed, FileEvent.Deleted, FileEvent.Moved, FileEvent.Renamed
 
Field Summary
 
Fields inherited from class java.util.EventObject
source
 
Constructor Summary
FileEvent.Renamed(FileWatcher source, java.io.File newFile, java.io.File oldFile)
           
 
Method Summary
protected  void dispatch(FileEventsListener listener)
          Implementing events should call an appropriate method of the listener passing itself as a parameter of the corresponding listener's method.
 java.io.File getOldFile()
           
 java.lang.String toString()
           
 
Methods inherited from class com.teamdev.filewatch.FileEvent
getEventId, getFile, getNativeKind, setEventId
 
Methods inherited from class java.util.EventObject
getSource
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

FileEvent.Renamed

public FileEvent.Renamed(FileWatcher source,
                         java.io.File newFile,
                         java.io.File oldFile)
Method Detail

getOldFile

public java.io.File getOldFile()
Returns:
instance with the previous name of the file.

toString

public java.lang.String toString()
Overrides:
toString in class FileEvent

dispatch

protected void dispatch(FileEventsListener listener)
Description copied from class: FileEvent
Implementing events should call an appropriate method of the listener passing itself as a parameter of the corresponding listener's method.

Specified by:
dispatch in class FileEvent
Parameters:
listener - a listener to notify.