Overview | Package | Class | Tree | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## de.grogra.pf.ui.edit
Interface Selection

All Superinterfaces:
  Described

All Known Subinterfaces:
  GraphSelection

All Known Implementing Classes:
  FieldSelection, GraphSelectionImpl, MapSource, NodeSelection, ObjectSelection, OptionsSelection, SelectionBase

    public interface Selection

extends Described

A `Selection` represents a selection for the GUI. Only instances of `Selection` may be used as values of the workbench selection (see `UIProperty.WORKBENCH_SELECTION`).

Author:
  Ole Kniemeyer

Field Summary
`static int` | `DELETABLE` Capability flag indicating that this selection can be deleted by `delete(boolean)`.
`static int` | `HIERARCHICAL` Capability flag indicating that this selection is part of a hierarchical structure.
`static int` | `TRANSFERABLE` Capability flag indicating that this selection can be converted to `Transferable` via `toTransferable(boolean)`.

Fields inherited from interface de.grogra.util.Described
`ACCELERATOR_KEY, ICON, MNEMONIC_KEY, NAME, SHORT_DESCRIPTION, TITLE`

Method Summary
`ComponentWrapper` | `createPropertyEditorComponent()` Returns an editor component for the GUI.
`ComponentWrapper` | `createPropertyEditorMenu()` Returns an editor menu component for the GUI.
`void` | `delete(boolean includeChildren)` Deletes this selection.
`int` | `getCapabilities()` Returns the capabilities of this selection.
`Context` | `getContext()`
`java.awt.datatransfer.Transferable` | `toTransferable(boolean includeChildren)` Converts this selection into `Transferable` for the clipboard.

Methods inherited from interface de.grogra.util.Described
`getDescription`

Field Detail

### DELETABLE

    static final int DELETABLE

  Capability flag indicating that this selection can be deleted by `delete(boolean)`.

  See Also:
    Constant Field Values

### HIERARCHICAL

    static final int HIERARCHICAL

  Capability flag indicating that this selection is part of a hierarchical structure.

  See Also:
    Constant Field Values

### TRANSFERABLE

    static final int TRANSFERABLE

  Capability flag indicating that this selection can be converted to `Transferable` via `toTransferable(boolean)`.

  See Also:
    Constant Field Values

Method Detail

### createPropertyEditorComponent

    ComponentWrapper createPropertyEditorComponent()

  Returns an editor component for the GUI. The component is used in in the GUI to edit the properties of this selection.

  Returns:
    a component responsible for editing this selection

### createPropertyEditorMenu

    ComponentWrapper createPropertyEditorMenu()

  Returns an editor menu component for the GUI. The component is used in in the GUI to edit the properties of this selection as part of a menu.

  Returns:
    a menu component responsible for editing this selection

### delete

    void delete(boolean includeChildren)

  Deletes this selection. The precise semantics of deletion depends on the selection. This method is only invoked if this selection has the capability `DELETABLE`.

  Parameters:
    `includeChildren` - `true` iff children in the hierarchy shall be included

### getCapabilities

    int getCapabilities()

  Returns the capabilities of this selection. The returned value is a combination of the flags `TRANSFERABLE`, `DELETABLE`, `HIERARCHICAL`.

  Returns:
    this selection's capabilities

### getContext

    Context getContext()

### toTransferable

    java.awt.datatransfer.Transferable toTransferable(boolean includeChildren)

  Converts this selection into `Transferable` for the clipboard. This method is only invoked if this selection has the capability `TRANSFERABLE`.

  Parameters:
    `includeChildren` - `true` iff children in the hierarchy shall be included
  Returns:
    a transferable object representing the data of this selection

Overview | Package | Class | Tree | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD