Re: Representing varargs

Linus Tolke Tigris <[email protected]> Tue, 10 May 2011 16:54:54 +0200
Newsgroups gmane.comp.lang.uml.argouml.user
Message-ID <[email protected]>
------=_Part_9170_1198772302.1305039297356
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit

Hello Mark!

I had a quick look in the UML Specification (UML 2.1.2 Superstructure) and
couldn't find anything about the varargs parameter. I presume that it can be
considered a shorthand for a parameter with an ordered list of elements of a
certain type. This paired with some instruction to the code generator/from
the reverse engineering to document in the model how this is realized in the
language.

The Generics in Java is similar to the Class Template when it comes to
Generic classes. In this case it is an Feature Template parameter (according
to the UML 2.1.2 Superstructure). I don't know to what extent this is
supported by ArgoUML though.

         /Linus


2011/5/9 Mark Fortner <[email protected]>

> I was wondering how to represent varargs in ArgoUML?  I have a method whose
> signature is
>
>  <T> java.util.Set<ConstraintViolation<http://jackson.codehaus.org/javadoc/bean-validation-api/1.0/javax/validation/ConstraintViolation.html>
> <T>> *validateProperty<http://jackson.codehaus.org/javadoc/bean-validation-api/1.0/javax/validation/Validator.html#validateProperty(T,+java.lang.String,+java.lang.Class...)>
> *(T object, java.lang.String propertyName, java.lang.Class<?>... groups)
> And I'm trying to figure out how to represent the groups parameter.  The
> generics in the return parameter also seem to be problematic.
>
> Any suggestions would be helpful.
>
> Regards,
>
> Mark
>

------------------------------------------------------
http://argouml.tigris.org/ds/viewMessage.do?dsForumId=449&dsMessageId=2733739

To unsubscribe from this discussion, e-mail: [[email protected]].
------=_Part_9170_1198772302.1305039297356
Content-Type: text/html; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable

Hello Mark!<br><br><div>I had a quick look in the UML Specification (UML 2.=
1.2 Superstructure) and couldn&#39;t find anything about the varargs parame=
ter. I presume that it can be considered a shorthand for a parameter with a=
n ordered list of elements of a certain type. This paired with some instruc=
tion to the code generator/from the reverse engineering to document in the =
model how this is realized in the language.</div>
<div><br></div><div>The Generics in Java is similar to the Class Template w=
hen it comes to Generic classes. In this case it is an Feature Template par=
ameter (according to the UML 2.1.2 Superstructure). I don&#39;t know to wha=
t extent this is supported by ArgoUML though.=A0</div>
<div><br></div><div>=A0 =A0 =A0 =A0 =A0/Linus</div><div><br><br><div class=
=3D"gmail_quote">2011/5/9 Mark Fortner <span dir=3D"ltr">&lt;<a href=3D"mai=
lto:[email protected]">[email protected]</a>&gt;</span><br><blockquote =
class=3D"gmail_quote" style=3D"margin:0 0 0 .8ex;border-left:1px #ccc solid=
;padding-left:1ex;">
I was wondering how to represent varargs in ArgoUML? =A0I have a method who=
se signature is=A0<div><br></div><div><table border=3D"1" width=3D"100%" ce=
llpadding=3D"3" cellspacing=3D"0" summary=3D"" style=3D"font-family:&#39;Ti=
mes New Roman&#39;;font-size:medium">

<tbody><tr bgcolor=3D"white" style=3D"background-color:rgb(255, 255, 255);c=
olor:rgb(0, 0, 0);background-repeat:initial initial">
<td align=3D"right" valign=3D"top" width=3D"1%"><font size=3D"-1"><code><ta=
ble border=3D"0" cellpadding=3D"0" cellspacing=3D"0" summary=3D""><tbody><t=
r align=3D"right" valign=3D""><td nowrap><font size=3D"-1"><code>&lt;T&gt; =
java.util.Set&lt;<a href=3D"http://jackson.codehaus.org/javadoc/bean-valida=
tion-api/1.0/javax/validation/ConstraintViolation.html" title=3D"interface =
in javax.validation" target=3D"_blank">ConstraintViolation</a>&lt;T&gt;&gt;=
</code></font></td>

</tr></tbody></table></code></font></td><td><code><b><a href=3D"http://jack=
son.codehaus.org/javadoc/bean-validation-api/1.0/javax/validation/Validator=
.html#validateProperty(T,+java.lang.String,+java.lang.Class...)" target=3D"=
_blank">validateProperty</a></b>(T=A0object, java.lang.String=A0propertyNam=
e, java.lang.Class&lt;?&gt;...=A0groups)</code>=A0</td>

</tr></tbody></table><br></div><div>And I&#39;m trying to figure out how to=
 represent the groups parameter. =A0The generics in the return parameter al=
so seem to be problematic.</div><div><br></div><div>Any suggestions would b=
e helpful.</div>

<div><br></div><div>Regards,</div><div><br></div><font color=3D"#888888"><d=
iv>Mark</div>
</font></blockquote></div><br></div>

------=_Part_9170_1198772302.1305039297356--