Before undertaking any programming task, there is a need to have a visualization of the program. Programmers make use of Unified Modeling Language to undertake the visualization of their programs. Systems design undergoes a lot of processes and stages. This is taken so that all the processes that are required have been made. This is the reason there is a need to have a thorough system analysis process when creating a system. System analysis entails having a thorough understanding of the system and what will need to be integrated and also looking at the possible bugs that might be introduced in the system. It is therefore important to have a physical representation of the system so that it becomes clear what needs to be achieved.
This paper will focus on the design of a book system where there are several classes that will print the book that has a specific value. The classes in the class diagrams show the aspect of inheritance in the design. This helps in getting other attributes from the parent classes so that there is the avoidance of repetition. Classes and objects help the programmer to understand the relationship that is found in a system.
Flow chart diagram
The flow chart of the system is shown in the diagram below:
For effective object oriented design, there is a need to have objects and classes well laid out, there is a need to understand inheritance and how code will be reused in the program. Objects are basically things which may include persons, places which are of significance to the system being designed or analyzed. It may also be graphical user interfaces or text areas on a display. Several objects may share some attributes or have common characteristics this object are grouped together into one class. E.g. class shapes with objects like Triangle, Circle, and rectangle. The classes may also have further subclasses with further defining attributes. Classes have unique create a distinction from other classes and avoid ambiguity. Objects are mainly instantiated from a class. Methods are behaviors attributed to objects of a particular class an object triangle may have methods e.g. area and circumference. Inheritance involves reuse of code associated with an object in a particular class.
CRC cards are used in object oriented analysis to represent the responsibilities and functions of classes and to enhance interaction and collaboration between the classes. CRC cards are used as an aid to help in getting objects which are not object oriented to think objects it is also a useful tool in validating the set of chosen classes to conform to the required behavior using models such as a use case model. CRC cards are an aid to clear thought, and it’s not an accepted part in the design process of a system. However UML permits the analyst to record the information from them in the class model. A CRC session entails identification of all possible classes, create all possible scenarios then finally identifying and defining responsibilities of the classes.
Unified modeling language is a programming language that is used to develop object oriented systems and programs. UML provides a set of notations for expressing models of Object
Oriented Analysis and Design (OOAD) .Currently the programming language is a de-facto standard for object oriented modeling and analysis.UML comprises of several diagrams that can be used to model the different aspects of the program or system to be modeled. Among these diagrams is the use case model which is a technique for modeling system functionality based on the users’ perspective. Use case model follows a sequence of actions which are aimed at achieving a particular goal, system requirements of the new system are captured using use case diagrams. The functionality of the system is partitioned or split into major parts the actors and use cases. Actors depict the roles played by the system users, these system users could be humans, computers, other hardware and even software that must be external to the system being portioned for analysis. The Actors must therefore be external and be able to stimulate the system and receive results and outputs from the system.
Use cases on the other hand describe the behavior of the system in the event of stimulation by any of the actors. The behavior is then documented or described textually. It describes the inputs and outputs from the actors in the process of conversion of the inputs to produce the outputs and the effects of the outputs to the other actors of the system. A use case also describes errors that can be encountered in the process of conversion of input to output and explains the possible mitigation measures. An example is point of sale system, the actors of the system would include, customer and the sales clerk. Both of these actors stimulate the system by feeding in some input and expect outputs from the system.
UML also employs several other diagrams used for system analysis. A class diagram shows an overview of a system by exhibiting its classes and their relationships they are always static showing only the interactive elements not the way they interact.Sequence diagram is basically an interaction diagram that explains how operations are conducted and at what instance. They are organized according to time. The time progresses as you go down the page. The objects involved in the operation are listed from left to right according to the stipulated or assigned time they should take part in the message sequence.Another diagram is the activity diagram which is essentially a flow chart it mainly focuses on the flow of tasks and activities involved in a process in the system .it also gives details and illustrations of how those activities relate and depend on each other.
Object oriented programming is gaining popularity in the programming field due to the benefits it has over other programming paradigms. OOP languages are easy to learn with a lot of code simplification thus the programmer is saved the hustle of writing numerous codes, the use of inheritance also allows for code re use thus simplifying program designing and coding. OOP is also quite responsive to changes undertaken and the changes may be implemented to individual objects which do not call for a system overhaul.Through encapsulation there is simplicity and effectiveness in object interaction and communication thus testing, debugging and system maintenance is simplified. Easier to manage because of the fact that the code can be reused and also because the functionality is modeled using objects and classes. It is possible to use code which has been written before. There is code re-use. With object oriented programming, there is a lot of flexibility because it is possible to get code which performs the same function for a given functionality.