|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjavax.swing.AbstractAction
de.uni_paderborn.fujaba.coobra.actions.CopyAction
Copy some ASGElements (changes to them) via CoObRA
Nested Class Summary | |
static class |
CopyAction.CopyData
Instances of this class store data for copying object with CoObRA |
Nested classes inherited from class javax.swing.AbstractAction |
|
Field Summary | |
private static CopyAction.CopyData |
clipboard
what has been copied |
private java.util.Map |
compartmentLinks
a map of compartment links: either ("fieldName", null) to copy all objects that link to another copied object via fieldName or (ObjectClass.class, "fieldName") to copy all objects that link to another copied object of class ObjectClass via fieldName |
private CopyAction.CopyData |
copyData
data for copying |
private static org.apache.log4j.Logger |
L
Logger |
(package private) de.upb.tools.fca.FDuplicatedHashMap |
newValueToChangesMap
map from object to all changes having the key as new value |
private java.util.Set |
possiblyIgnoredValues
(possibly) ignored values when determining which changes to copy |
Fields inherited from class javax.swing.AbstractAction |
changeSupport, enabled |
Fields inherited from interface javax.swing.Action |
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SHORT_DESCRIPTION, SMALL_ICON |
Constructor Summary | |
CopyAction()
Defines an Action object with a default description string and default icon. |
|
CopyAction(CopyAction.CopyData copyData)
Create a copy action with a specific data storage |
Method Summary | |
void |
actionPerformed(java.awt.event.ActionEvent e)
Invoked when the action occurs. |
private void |
addReferencedObjectsFromChanges(FElement element)
add all objects referenced in changes that have element as new value |
private void |
addToCopyObjects(FElement element)
Adds an element to the getCopyData().getCopyObjects() set. |
void |
copy()
complete the CopyData with the copyObjects and copyChanges data. |
static CopyAction.CopyData |
getClipboard()
|
CopyAction.CopyData |
getCopyData()
|
private void |
init()
initialize sets |
private void |
putChangesIntoHashMap(java.util.Iterator it)
adds changes to newValueToChangesMap |
Methods inherited from class javax.swing.AbstractAction |
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled |
Methods inherited from class java.lang.Object |
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
private static CopyAction.CopyData clipboard
private java.util.Set possiblyIgnoredValues
private java.util.Map compartmentLinks
private CopyAction.CopyData copyData
de.upb.tools.fca.FDuplicatedHashMap newValueToChangesMap
private static final org.apache.log4j.Logger L
Constructor Detail |
public CopyAction(CopyAction.CopyData copyData)
copyData
- where object to be copied reside (selectedObjects) and the data for
copying will be enteredpublic CopyAction()
Action
object with a default description string and default icon.
Method Detail |
public static CopyAction.CopyData getClipboard()
public CopyAction.CopyData getCopyData()
private void init()
public void actionPerformed(java.awt.event.ActionEvent e)
e
- event that caused the actionpublic void copy()
private void addToCopyObjects(FElement element)
element
- what to copyprivate void addReferencedObjectsFromChanges(FElement element)
element
as new value
element
- ASGElement that was already addedprivate void putChangesIntoHashMap(java.util.Iterator it)
newValueToChangesMap
it
- iterator through changes
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |