Discussion:
Representing varargs
Mark Fortner
2011-05-09 17:28:41 UTC
Permalink
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=2733416

To unsubscribe from this discussion, e-mail: [users-***@argouml.tigris.org].
Linus Tolke Tigris
2011-05-10 14:54:54 UTC
Permalink
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
Post by Mark Fortner
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: [users-***@argouml.tigris.org].
Loading...