|
|
Re: Editor for non-unique references [message #425944 is a reply to message #425938] |
Fri, 12 December 2008 21:54 |
Ed Merks Messages: 33142 Registered: July 2009 |
Senior Member |
|
|
This is a multi-part message in MIME format.
--------------000707050006080800000803
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 7bit
Stefan,
Comments below.
Stefan Schulze wrote:
> Hi...
>
> I have a problem regarding the generated editor. If I have an
> not-containing, not-unique reference with upperBound>1 (or -1), is it right,
> that it's impossible to add the same object to an reference-instance more
> than one time?
>
If you search the newsgroups, you'll find this comes up every so often.
<https://bugs.eclipse.org/bugs/show_bug.cgi?id=89325>
https://bugs.eclipse.org/bugs/show_bug.cgi?id=89325
> For example:
> I have a class "Wallet" and a class "Coin". The wallet has a not-containing
> reference to multiple coins.
>
> In the generated editor I added some coins to an containing Object and I try
> to add the 50cent-Coin more than one time to my wallet. Is it right, that
> this is not possible?
>
> I'm still sticking at EMF 2.3.2 (because of some dependencies). Is this
> possibly already fixed in a newer version or is there any workaround?
>
You can override the getter to specialize the returned list so that
isUnique returns false, but there's no guarantee the rest of the
framework will be happy.
> Bye,
> Stefan
>
>
>
--------------000707050006080800000803
Content-Type: text/html; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html;charset=ISO-8859-1" http-equiv="Content-Type">
</head>
<body bgcolor="#ffffff" text="#000000">
Stefan,<br>
<br>
Comments below.<br>
<br>
Stefan Schulze wrote:
<blockquote cite="mid:ghttpc$cab$1@build.eclipse.org" type="cite">
<pre wrap="">Hi...
I have a problem regarding the generated editor. If I have an
not-containing, not-unique reference with upperBound>1 (or -1), is it right,
that it's impossible to add the same object to an reference-instance more
than one time?
</pre>
</blockquote>
If you search the newsgroups, you'll find this comes up every so often.<a
href="https://bugs.eclipse.org/bugs/show_bug.cgi?id=89325"><br>
</a>
<blockquote><a
href="https://bugs.eclipse.org/bugs/show_bug.cgi?id=89325">https://bugs.eclipse.org/bugs/show_bug.cgi?id=89325</a><br>
</blockquote>
<blockquote cite="mid:ghttpc$cab$1@build.eclipse.org" type="cite">
<pre wrap="">
For example:
I have a class "Wallet" and a class "Coin". The wallet has a not-containing
reference to multiple coins.
In the generated editor I added some coins to an containing Object and I try
to add the 50cent-Coin more than one time to my wallet. Is it right, that
this is not possible?
I'm still sticking at EMF 2.3.2 (because of some dependencies). Is this
possibly already fixed in a newer version or is there any workaround?
</pre>
</blockquote>
You can override the getter to specialize the returned list so that
isUnique returns false, but there's no guarantee the rest of the
framework will be happy.<br>
<blockquote cite="mid:ghttpc$cab$1@build.eclipse.org" type="cite">
<pre wrap="">
Bye,
Stefan
</pre>
</blockquote>
</body>
</html>
--------------000707050006080800000803--
Ed Merks
Professional Support: https://www.macromodeling.com/
|
|
|
Powered by
FUDForum. Page generated in 0.08085 seconds