Abstract Classes, Interfaces and Uses Relationship
Abstract classes are depicted in italics.
The abstract behaviors need to be overwritten in subclasses and will have to be done manually for each subclass.
Notice that the behaviors in an abstract class are also written in italics.
That's ok for abstract methods, but in Java not all methods in an abstract class need to be abstract.
Unfortunately, Rose writes even the names of non-abstract behaviors in italics.
An interface is depicted in UML as a class with the "stereotype" interface.
(Stereotypes are means of extending UML).
A stereotype is enclosed in "<<" and ">>" symbols.
A class that implements an interface needs to be connected to the interface by a "realize" edge (like the "generalize" edge between a superclass and subclass, only hyphenated).
If some of the elements have a special feature, a custom stereotype can be defined.
For example, if it is important that the diagram depict that a class creates an object of another class, you can define a stereotype <<creates>> for a "uses" relationship.
The uses or depends relation is depicted as a directed dashed line.
A class uses another class if it only refers to it implicitly, i.e. it doesn't specify any associations to it.
A container class or a class declaring another class as an instance variable is a typical example of such use.
The author has over three and a half years of experience on developing web and object oriented application with a development focus on server side and enterprise Java .He is a regular writer for the European publication "Programmez!" and writes on and of for some online publications. He can be reached at sameertyagi@usa.net
JavaBytes
Internet Cyclone
This powerful, easy-to-use, internet optimizer is for
Windows 95, 98, ME, NT, 2000 and XP. It's designed to
automatically optimize your Windows settings, boosting your
Internet connection up to 200%.
Blackmail Applet
This applet prints out text that looks like letters cut out of a
newspaper. You can specify the text, the width and height of the
applet and the delay after each letter. Future versions will
have more parameters.
While surveys suggest that small businesses aren't prepared for ever-present security dangers, this Boston-area printer has maintained a pristine operation since a scare six years ago.