O
Oskar Bennet
Hi everybody,
I am supposed to draw a simple UML diagram for a very small project that
consists of less than a dozen classes. I have never been working with
UML before, I have read some tutorials but I cannot find the connection
between UML and my C++ code.
What I have found out so far is that inheritance is indicated by an
arrow like this
|\
------| >
|/
But I am not quite sure what type of connection is required between two
classes that are related the follwing way:
class myDataType
{
int foo;
...
}
class listElement
{
myDataType bar;
...
}
This is not what I would call inheritance so I assume that there is a
different type of connector. Does anybody have a clue of how to connect
these two classes in an UML diagram? I believe it could be similar to
this, but I am not really sure:
<>----------->
What would be the difference in an UML diagram if the second class would
be using a vector like that:
class listElement
{
<vector>::myDataType bar;
}
Maybe someone can recommend a _good_ UML tutorial that explains the
basics of UML in a way that is related to C++, all tutorials I found so
far are only rubbish.
Thanks in advance!
Oskar
PS.: Does anybody know a good tool for drawing UML diagrams? I just have
tried out dia but it is not very comfortable to use.
I am supposed to draw a simple UML diagram for a very small project that
consists of less than a dozen classes. I have never been working with
UML before, I have read some tutorials but I cannot find the connection
between UML and my C++ code.
What I have found out so far is that inheritance is indicated by an
arrow like this
|\
------| >
|/
But I am not quite sure what type of connection is required between two
classes that are related the follwing way:
class myDataType
{
int foo;
...
}
class listElement
{
myDataType bar;
...
}
This is not what I would call inheritance so I assume that there is a
different type of connector. Does anybody have a clue of how to connect
these two classes in an UML diagram? I believe it could be similar to
this, but I am not really sure:
<>----------->
What would be the difference in an UML diagram if the second class would
be using a vector like that:
class listElement
{
<vector>::myDataType bar;
}
Maybe someone can recommend a _good_ UML tutorial that explains the
basics of UML in a way that is related to C++, all tutorials I found so
far are only rubbish.
Thanks in advance!
Oskar
PS.: Does anybody know a good tool for drawing UML diagrams? I just have
tried out dia but it is not very comfortable to use.