org.apache.log4j.chainsaw.dnd

## Class FileDnDTarget

- java.lang.Object
- - org.apache.log4j.chainsaw.dnd.FileDnDTarget

- All Implemented Interfaces:
    DropTargetListener, EventListener

      public class FileDnDTarget
      extends Object
      implements DropTargetListener

  This class provides all the functionality to work out when files are dragged onto a particular JComponent instance, and then notifies listeners via the standard PropertyChangesListener semantics to indicate that a list of files have been dropped onto the target. If you wish to know whan the files have been dropped, subscribe to the "fileList" property change.
  Author:
    psmith

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `protected int` | `acceptableActions`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `FileDnDTarget(JComponent c)`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `addDropTargetToComponent(JComponent c)`
    `void` | `addPropertyChangeListener(PropertyChangeListener listener)`
    `void` | `addPropertyChangeListener(String propertyName, PropertyChangeListener listener)`
    `void` | `dragEnter(DropTargetDragEvent e)`
    `void` | `dragExit(DropTargetEvent dte)`
    `void` | `dragOver(DropTargetDragEvent e)`
    `void` | `drop(DropTargetDropEvent dtde)`
    `void` | `dropActionChanged(DropTargetDragEvent dtde)`
    `List` | `getFileList()`
    `void` | `removePropertyChangeListener(PropertyChangeListener listener)`
    `void` | `removePropertyChangeListener(String propertyName, PropertyChangeListener listener)`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Field Detail

    - #### acceptableActions

          protected int acceptableActions

  - ### Constructor Detail

    - #### FileDnDTarget

          public FileDnDTarget(JComponent c)

  - ### Method Detail

    - #### addDropTargetToComponent

          public void addDropTargetToComponent(JComponent c)

    - #### addPropertyChangeListener

          public void addPropertyChangeListener(PropertyChangeListener listener)

      Parameters:
        `listener` -

    - #### addPropertyChangeListener

          public void addPropertyChangeListener(String propertyName,
                                                PropertyChangeListener listener)

      Parameters:
        `propertyName` -
        `listener` -

    - #### dragEnter

          public void dragEnter(DropTargetDragEvent e)

      Specified by:
        `dragEnter` in interface `DropTargetListener`

    - #### dragExit

          public void dragExit(DropTargetEvent dte)

      Specified by:
        `dragExit` in interface `DropTargetListener`

    - #### dragOver

          public void dragOver(DropTargetDragEvent e)

      Specified by:
        `dragOver` in interface `DropTargetListener`

    - #### drop

          public void drop(DropTargetDropEvent dtde)

      Specified by:
        `drop` in interface `DropTargetListener`

    - #### dropActionChanged

          public void dropActionChanged(DropTargetDragEvent dtde)

      Specified by:
        `dropActionChanged` in interface `DropTargetListener`

    - #### getFileList

          public final List getFileList()

      Returns:
        Returns the fileList.

    - #### removePropertyChangeListener

          public void removePropertyChangeListener(PropertyChangeListener listener)

      Parameters:
        `listener` -

    - #### removePropertyChangeListener

          public void removePropertyChangeListener(String propertyName,
                                                   PropertyChangeListener listener)

      Parameters:
        `propertyName` -
        `listener` -

Copyright © 2002-2018 Apache Software Foundation. All Rights Reserved.
Apache Logging, Apache Log4j, Log4j, Apache Chainsaw, Chainsaw, Apache, the Apache feather logo, the Apache Logging project logo, and the Apache Log4j logo are trademarks of The Apache Software Foundation.