Overview: was to create two classes in visual paradigm

Overview:

In this task
I will analyse what a UML class diagram is as well as what the main elements
are that that come together to constitute a class diagram, e.g. Attributes,
operations and relationships between classes. I will also examine the purpose a
class diagram serves and explain what team members in the software development
life cycle (SLDC) uses them. For this assignment I will be using Visual
paradigm to develop a java class diagram and note the steps involved.

We Will Write a Custom Essay Specifically
For You For Only $13.90/page!


order now

Assignment:

A class
diagram is a type of structure diagram which is used to illustrate what must be
present in the system currently being modelled. Class diagrams help to separate
the design elements from the coding of the system. Classes are often referred
to as “the building block of objects” in object-oriented programming, ergo,
class diagrams are also the building blocks of UML.  They have a number or benefits, allowing users
to:

·        
Illustrate
data models for complex systems, no matter how simple or complex.

·        
Better
understand the general overview of the schematics of an application.

·        
Visually
express any specific needs of a system and disseminate that information
throughout the business.

·        
Create
detailed charts that highlight any specific code needed to be programmed and
implemented to the described structure.

·        
Provide
an implementation-independent description of types used in a system that are
later passed between its components. *(1)

A “class” is a rectangular shape containing three areas stacked
vertically. To demonstrate this I opened visual paradigm and started a new
project as shown in the image below.

 

 

 

 

 

 

 

I entered the name of the project as Task 6
and selected UML as the data type set. Although I had the option to, I chose
not to put in a description for my class diagram. I then chose “class-diagram”
as the type of diagram I wished to create.

 

My next step was to create two classes in visual paradigm and
assign an attribute with getter and setter to it, which is shown in the fourth
screenshot below. An attribute defines values that can be attached to instances
of the class. I am also able to add operations to classes which is a method or
function that can be performed by an instance of a class. Classes can also have
a number of special relationships between each other. Dependancy is a
connection between two or more classes it
exists between two elements if changes to the definition of one element (the
server or target) may cause changes to the other (the client or source). This
association is uni-directional. An “association” represents a group of
links. An association can link any number of classes. An association with three
links is called a ternary association. Associations can be named as well as
given role name, ownership indicators, multiplicity and visibility.

 

Finally, to
generate java code from the class diagram I have shown thus far in visual
paradigm I navigate to the tools tab, select code and the select “generate java
code” which will convert my class diagram into useable java code.