I have created a simple FlappyBird clone game with socket programming and now I am doing the UML diagram. My classes implements Runnable
Like:
static class Flappy implements Runnable{....}
and:
public class Client extends Application implements Runnable{.....}
UML is methodology agnostic. So, it all depends on the purpose of your class diagram:
Runnable
is not relevant (as the other answer rightly pointed out)Runnable
is for your design:
Runnable
, you don’t need to show it.Runnable
or if the class is expected to provide this interface in the larger view of the component design, then you should show it.Runnable
should be documented. Be aware that the use of such detailed implementation models is good for school-work but is not an interesting option for real world projects because it’s difficult to maintain and somewhat redundant with the code, unless you have reverse-engineering tools that can generate the diagram for you.If you decide to show the relation, you’ll have to rework your graphical layout:
Runnable
is an interface, and your classes implement
it and do not extend
it, you should use a dashed line to show that it’s the realization of an interface (which is a dependency, with a slightly different meaning that the inheritance/generalization).