Package com.nomagic.magicdraw.ui
Class SelectionProvider
java.lang.Object
com.nomagic.magicdraw.ui.SelectionProvider
Selection provider to manage selected elements in browser and diagrams
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic interface
static class
An event which indicates selection change.static interface
Selection changed listener -
Field Summary
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
Adds selection changed listenerprotected void
static SelectionProvider
getInstance
(Project project) Returns selection providerfinal BaseElement
Returns main elementfinal Collection<? extends BaseElement>
Returns selected elementsvoid
Removes selection changed listener
-
Field Details
-
selection
-
-
Constructor Details
-
SelectionProvider
public SelectionProvider()
-
-
Method Details
-
getInstance
Returns selection provider- Parameters:
project
- where are selected elements- Returns:
- selection provider
-
getSelection
- Returns:
- active selection
-
getSelectedElements
Returns selected elements -
getMainElement
Returns main element -
addSelectionChangedListener
Adds selection changed listener- Parameters:
listener
- to add
-
removeSelectionChangedListener
Removes selection changed listener- Parameters:
listener
- to remove
-
fireSelectionChanged
-