Class FileSystemListenerList

  • All Implemented Interfaces:
    FileSystemListener

    public class FileSystemListenerList
    extends java.lang.Object
    implements FileSystemListener
    FileSystemListenerList maintains a list of FileSystemListener's. This class, acting as a FileSystemListener, simply relays each callback to all FileSystemListener's within its list. Employs either a synchronous and asynchronous notification mechanism.
    • Constructor Summary

      Constructors 
      Constructor Description
      FileSystemListenerList​(boolean enableAsynchronousDispatching)
      Construct FileSystemListenerList
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void add​(FileSystemListener listener)
      Add a listener to this list.
      void clear()
      Remove all listeners from this list.
      void dispose()  
      void folderCreated​(java.lang.String parentPath, java.lang.String folderName)
      Forwards folderCreated callback to all listeners within this list.
      void folderDeleted​(java.lang.String parentPath, java.lang.String folderName)
      Forwards folderDeleted callback to all listeners within this list.
      void folderMoved​(java.lang.String parentPath, java.lang.String folderName, java.lang.String newParentPath)
      Forwards folderMoved callback to all listeners within this list.
      void folderRenamed​(java.lang.String parentPath, java.lang.String folderName, java.lang.String newFolderName)
      Forwards folderRenamed callback to all listeners within this list.
      boolean isProcessingEvents()
      Returns true if this class is processing events or needs to process events that are in its event queue.
      void itemChanged​(java.lang.String parentPath, java.lang.String itemName)
      Forwards itemChanged callback to all listeners within this list.
      void itemCreated​(java.lang.String parentPath, java.lang.String itemName)
      Forwards itemCreated callback to all listeners within this list.
      void itemDeleted​(java.lang.String parentPath, java.lang.String itemName)
      Forwards itemDeleted callback to all listeners within this list.
      void itemMoved​(java.lang.String parentPath, java.lang.String name, java.lang.String newParentPath, java.lang.String newName)
      Forwards itemMoved callback to all listeners within this list.
      void itemRenamed​(java.lang.String parentPath, java.lang.String itemName, java.lang.String newName)
      Forwards itemRenamed callback to all listeners within this list.
      void remove​(FileSystemListener listener)
      Remove a listener from this list.
      void syncronize()
      Forwards syncronize callback to all listeners within this list.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • FileSystemListenerList

        public FileSystemListenerList​(boolean enableAsynchronousDispatching)
        Construct FileSystemListenerList
        Parameters:
        enableAsyncronousDispatching - if true a seperate dispatch thread will be used to notify listeners. If false, blocking notification will be performed.
    • Method Detail

      • dispose

        public void dispose()
      • add

        public void add​(FileSystemListener listener)
        Add a listener to this list.
        Parameters:
        listener -
      • remove

        public void remove​(FileSystemListener listener)
        Remove a listener from this list.
        Parameters:
        listener -
      • clear

        public void clear()
        Remove all listeners from this list.
      • itemMoved

        public void itemMoved​(java.lang.String parentPath,
                              java.lang.String name,
                              java.lang.String newParentPath,
                              java.lang.String newName)
        Forwards itemMoved callback to all listeners within this list.
        Specified by:
        itemMoved in interface FileSystemListener
        Parameters:
        parentPath - the path of the folder that used to contain the item.
        newParentPath - the path of the folder that the item was moved to.
        newName - the new name of the item.
        See Also:
        ghidra.framework.store.FileSystemListener#itemMoved(java.lang.String, java.lang.String, java.lang.String)
      • folderMoved

        public void folderMoved​(java.lang.String parentPath,
                                java.lang.String folderName,
                                java.lang.String newParentPath)
        Forwards folderMoved callback to all listeners within this list.
        Specified by:
        folderMoved in interface FileSystemListener
        Parameters:
        parentPath - the path of the folder that used to contain the moved folder.
        folderName - the name of the folder that was moved.
        newParentPath - the path of the folder that now contains the moved folder.
        See Also:
        FileSystemListener.folderMoved(java.lang.String, java.lang.String, java.lang.String)
      • isProcessingEvents

        public boolean isProcessingEvents()
        Returns true if this class is processing events or needs to process events that are in its event queue.
        Returns:
        true if this class is processing events or needs to process events that are in its event queue.