Dear list, I notice that when considering a class containing only frozen attributes, argo (0.28) suggests defining it as utility or defining instance variables. I don't understand this advice, is it adequate? IMHO, a frozen attribute is an instance attribute anyway (why does it talk about a "variable" btw?). And I don't think that the utility stereotype applies to entities, i.e. model objects, even if they are immutable. See hereby a sample xmi and zargo project, and below an example java class, which trigger the critic.
package argo.simple;
public class ValueContainer {
private final int m_value;
public ValueContainer(int value) {
m_value = value;
}
public int getValue() {
return m_value;
}
}
Please tell me if I am misunderstanding something.
Olivier
------------------------------------------------------
http://argouml.tigris.org/ds/viewMessage.do?dsForumId=449&dsMessageId=2366069
To unsubscribe from this discussion, e-mail:
[[email protected]].<XMI xmi.version = '1.2' xmlns:UML = 'org.omg.xmi.namespace.UML' timestamp = 'Sun Jun 28 10:07:50 CEST 2009'>
<XMI.header> <XMI.documentation>
<XMI.exporter>ArgoUML (using Netbeans XMI Writer version 1.0)</XMI.exporter>
<XMI.exporterVersion>0.28(6) revised on $Date: 2007-05-12 08:08:08 +0200 (Sat, 12 May 2007) $ </XMI.exporterVersion>
</XMI.documentation>
<XMI.metamodel xmi.name="UML" xmi.version="1.4"/></XMI.header>
<XMI.content>
<UML:Model xmi.id = '127-0-0-1-727bffc7:12225b0e080:-8000:000000000000184B'
name = 'simple' isSpecification = 'false' isRoot = 'false' isLeaf = 'false'
isAbstract = 'false'>
<UML:Namespace.ownedElement>
<UML:Class xmi.id = '127-0-0-1-727bffc7:12225b0e080:-8000:000000000000184C'
name = 'ValueContainer' visibility = 'public' isSpecification = 'false'
isRoot = 'false' isLeaf = 'false' isAbstract = 'false' isActive = 'false'>
<UML:Classifier.feature>
<UML:Attribute xmi.id = '127-0-0-1-727bffc7:12225b0e080:-8000:000000000000184D'
name = 'value' visibility = 'public' isSpecification = 'false' ownerScope = 'instance'
changeability = 'frozen' targetScope = 'instance'>
<UML:StructuralFeature.multiplicity>
<UML:Multiplicity xmi.id = '127-0-0-1-727bffc7:12225b0e080:-8000:000000000000184E'>
<UML:Multiplicity.range>
<UML:MultiplicityRange xmi.id = '127-0-0-1-727bffc7:12225b0e080:-8000:000000000000184F'
lower = '1' upper = '1'/>
</UML:Multiplicity.range>
</UML:Multiplicity>
</UML:StructuralFeature.multiplicity>
<UML:StructuralFeature.type>
<UML:DataType href = 'http://argouml.org/profiles/uml14/default-java.xmi#.:000000000000086C'/>
</UML:StructuralFeature.type>
</UML:Attribute>
<UML:Operation xmi.id = '127-0-0-1-727bffc7:12225b0e080:-8000:0000000000001852'
name = 'ValueContainer' visibility = 'public' isSpecification = 'false'
ownerScope = 'instance' isQuery = 'false' concurrency = 'sequential' isRoot = 'false'
isLeaf = 'false' isAbstract = 'false'>
<UML:ModelElement.stereotype>
<UML:Stereotype href = 'http://argouml.org/profiles/uml14/default-uml14.xmi#.:000000000000082B'/>
</UML:ModelElement.stereotype>
<UML:BehavioralFeature.parameter>
<UML:Parameter xmi.id = '127-0-0-1-727bffc7:12225b0e080:-8000:0000000000001853'
name = 'return' isSpecification = 'false' kind = 'return'>
<UML:Parameter.type>
<UML:DataType href = 'http://argouml.org/profiles/uml14/default-java.xmi#.:000000000000086B'/>
</UML:Parameter.type>
</UML:Parameter>
<UML:Parameter xmi.id = '127-0-0-1-727bffc7:12225b0e080:-8000:0000000000001854'
name = 'value' isSpecification = 'false' kind = 'in'>
<UML:Parameter.type>
<UML:DataType href = 'http://argouml.org/profiles/uml14/default-java.xmi#.:000000000000086C'/>
</UML:Parameter.type>
</UML:Parameter>
</UML:BehavioralFeature.parameter>
</UML:Operation>
</UML:Classifier.feature>
</UML:Class>
</UML:Namespace.ownedElement>
</UML:Model>
</XMI.content>
</XMI>
simpleEntity.xmi.zargo
Description: Binary data
