\subsection{Class}
A class is an abstraction of similar objects. A class is a set of objects that share a common structure, common behavior, and common semantics \cite{23}. During the analysis stage, individual object instances are identified and then grouped into general classes. A class is defined by defining the attributes and methods of its objects.

Attributes refer to data belonging to a class. Collectively, the attributes of an object represent its state. There are three types of attributes: single-valued, multiplicity or multivalued attribute. There are also attributes that refer to other objects or instance connections.

Instances of a class exhibit behavior when they execute their methods. A method contains logic operations of the class.

\subsection{Class Collaboration}
Class collaboration refers to the cooperation between a class and other classes in implementing its responsibilities. Responsibilities are implemented in terms of methods. For each method, a class can perform the method on its own, or it needs to collaborate and communicate with other classes.

Responsibility is a function that a class needs to fulfill. A class should not have too many responsibilities. This is the principle of cohesion \cite{24}. Cohesion reflects the single purpose of a class. Highly cohesive components can reflect lower coupling between classes because only minimal information needs to be passed between them. The concept of class cohesion means that all the class's methods and attributes to be used by internal methods and derived classes' methods.

Interaction means the relation of a class and other class. Classes communicate through messaging. Message is a request service that an object sends to another object and communication is the collaboration between classes in order to perform a responsibility.

\subsection{Class Relationship}
Abstraction is a process of identifying the similarities between classes. Abstraction is defined as ``the essential characteristics of an object that distinguish it from all other kinds of objects and thus provide crisply defined conceptual boundaries, relative to the perspective of the viewer'' \cite{25}. During the abstraction process, the similarities of the classes are identified and this helps in the process of dividing the classes into hierarchies. The allowable behavior, which is the outside view of the object, is determined for the abstraction.

There are three relationships that are common among classes \cite{26}. The paragraphs below discuss those relationships.

\begin{itemize}
\item Association is a general dependency relationship between classes. For example, a class depends on another class if it manipulates objects of the other class. The UML notation for this relationship is just a plain line between the classes, as shown in Fig. \ref{figure_5}.
\end{itemize}

\begin{figure}
\centering
\includegraphics{figure_5.pdf}
\caption{Association Relationship}
\label{figure_5}
\end{figure}

\begin{itemize}
\item Aggregation is the association of a class with other component classes. It is also sometimes known as whole-part relationships or composition. In the UML notation, the line representing the relationship has a filled diamond at the ``whole'' end. An example of an aggregation relationship is depicted in Fig. \ref{figure_6}.
\end{itemize}

\begin{figure}
\centering
\includegraphics{figure_6.pdf}
\caption{Aggregation Relationship}
\label{figure_6}
\end{figure}

\begin{itemize}
\item Inheritance is the relationship that exists when a class inherits attributes and behavior from another class. The most general class will become the super class and other class is the sub-class. The sub-class inherits all the data and behavior of its parent, besides having its own data and methods. In the UML notation, the super-sub class relationship is represented as a line with a hollow triangle at the ``super class'' end. Fig \ref{figure_7} illustrates an example of inheritance.
\end{itemize}

\begin{figure}
\centering
\includegraphics{figure_7.pdf}
\caption{Inheritance Relationship}
\label{figure_7}
\end{figure}

Another concept related to class relationship is visibility. ``Visibility is the ability of one object to ``see'' or have a reference to another object'' \cite{27}. The protocol is the interface of the class operation and its visibility. One class need to be visible to another class in order to collaborate. The protocol can be either the member is public, private or protected. A class can be visible (has public protocol) to other classes or it can be hidden (has private protocol) from other classes. The visibility depends on the type of relationship.

\subsection{Class Encapsulation}
Encapsulation is one of the most important principles in object-orientation. It means that the object includes both data and operations on the data (methods). It is also known as information hiding. This is