Author: b00__1
Date: 2007-08-15 12:48:12-0700
New Revision: 13370
Modified:
branches/gsoc2007/b00__1/model-euml/src/org/argouml/model/euml/CoreHelperEUMLImpl.java
Log:
Refactor addOwnedElement
Modified: branches/gsoc2007/b00__1/model-euml/src/org/argouml/model/euml/CoreHelperEUMLImpl.java
Url: http://argouml.tigris.org/source/browse/argouml/branches/gsoc2007/b00__1/model-euml/src/org/argouml/model/euml/CoreHelperEUMLImpl.java?view=diff&rev=13370&p1=branches/gsoc2007/b00__1/model-euml/src/org/argouml/model/euml/CoreHelperEUMLImpl.java&p2=branches/gsoc2007/b00__1/model-euml/src/org/argouml/model/euml/CoreHelperEUMLImpl.java&r1=13369&r2=13370
==============================================================================
--- branches/gsoc2007/b00__1/model-euml/src/org/argouml/model/euml/CoreHelperEUMLImpl.java (original)
+++ branches/gsoc2007/b00__1/model-euml/src/org/argouml/model/euml/CoreHelperEUMLImpl.java 2007-08-15 12:48:12-0700
@@ -347,8 +347,9 @@
"Add the Behavior (method) # to the BehavioralFeature (operation) #",
method, handle));
}
-
- public void addOwnedElement(Object handle, Object me) {
+
+ public void addOwnedElement(Object handle, Object me, String msg,
+ Object... objects) {
if (!(handle instanceof Namespace)) {
throw new IllegalArgumentException(
"The handle must be instance of Namespace"); //$NON-NLS-1$
@@ -358,10 +359,12 @@
"'me' must be instance of Element"); //$NON-NLS-1$
}
editingDomain.getCommandStack().execute(
- new ChangeCommand(
- modelImpl, getRunnableClassForAddCommand(
- (Namespace) handle, (Element) me),
- "Add the owned element # to the owner #", me, handle));
+ new ChangeCommand(modelImpl, getRunnableClassForAddCommand(
+ (Namespace) handle, (Element) me), msg, objects));
+ }
+
+ public void addOwnedElement(Object handle, Object me) {
+ addOwnedElement(handle, me, "Add the owned element # to the owner #", me, handle);
}
public void addParameter(Object handle, int index, Object parameter) {
lmpx.com only provides a reader for public news (NNTP) servers. It is not
affiliated with the servers or forums shown here and is not responsible for
the content of articles, which is written by their respective authors.