Sie sind auf Seite 1von 13

Assignment

BC0057 OBJECT ORIENTED ANALYSIS AND DESIGN


Q1. Why is object oriented system important? State 2 orthogonal views of the software. Answer: The Benefits of Object Orientation are following: Faster development Reusability Increased quality Easier maintenance The object technology approach to problem solving has several important differences from traditional data processing systems. The first and most important is the absolute necessity of proper analysis before implementation Object-oriented vs. Traditional Analysis In software development, there are three main parts: analysis, design and programming. Analysis deals with understanding the user requirements and how these user requirements can be met using the appropriate computer technology. In many cases, systems analysis and design are done poorly and as a result, a system never reaches its real potential. Maintenance on these systems is always high, and the budget for these systems is always going through the roof because the infrastructure for the system was not properly described. It seems that many companies want results quickly and the first thing they skimp on is the effort required to perform a complete analysis and design. Many times what happens is that a system is developed in a vacuum, instead of analyzing how the system will interface with other systems and what will be needed to establish proper interfaces. In almost all cases, this approach leads to high maintenance costs and slower system development time. Many companies have found that while they could get away with a poor analysis and design, proper system analysis and design are an absolute necessity for object databases.
AMATULLHA SUMAIYA, Roll: 511127743 (BCA) SIKKIM MANIPAL UNIVERSITY, DE 1

As we know, in software development there are three major activities; analysis, design and programming. Traditional systems use the approach that when a change is needed, they modify only that which is necessary. Object-Oriented development uses a different approach. Object-oriented requires a well defined plan before any systems construction may be undertaken. Regardless of whether we use the traditional approach or the objectoriented approach the gains from doing a "quality analysis" are monumental. With proper analysis & design, there are many benefits of the object-oriented approach: Customers get better systems at less cost. Projects are done on time. Systems organizations and companies become more competitive. Maintenance for these systems is lower. Changes can be made to systems faster and with less cost.

One of the basic distinctions between traditional systems and objectoriented systems is the initiator for the processes. Object-oriented systems are event-driven, and unlike traditional systems where a process is triggered by the change to a data item. But how does an analyst shift from thinking about systems in the traditional way to thinking about systems as a collection of interacting objects? To understand the answer, let's take a look at object behavior analysis. Object behavior analysis is a new method which contains the following steps: Identify a hierarchy of behaviors for the entire system. Identify the "primitive" behaviors, and create a behavior hierarchy. Identify all objects which exhibit the behaviors, and create a class hierarchy. Associate each primitive behavior with each object class.

Orthogonal view of the software: A software system is a set of mechanism for performing certain action on certain data Algorithm + Data structure = Program

AMATULLHA SUMAIYA, Roll: 511127743 (BCA) SIKKIM MANIPAL UNIVERSITY, DE

Object-oriented systems development methods differ from traditional development techniques in that the traditional techniques view software, as a collection of programs (or functions) and isolated data What is a program? Algorithms + Data Structures = Programs: "A software system is a set of mechanisms for performing certain action on certain data." There are two different, yet complementary ways to view software construction: In traditional system, we can focus primarily on the functions or primarily on the data. The heart of the distinction between traditional system development methodologies and newer object-oriented methodologies lies in their primary focus, where the traditional approach focuses on the functions of the system. What is it doing?object-oriented systems development center on the object, which combines data and functionality.

Q2. Explain about Encapsulation & information hiding and Class hierarchy? Answer: Encapsulation: In Object Oriented Programming, encapsulation is an attribute of object design. It means that all of the object's data is contained and hidden in the object and access to it restricted to member of that class. In programming languages, encapsulation is used to refer to one of two related but distinct notions, and sometimes to the combination thereof: A language mechanism for restricting access to some of the object's components. A language construct that facilitates the bundling of data with the methods (or other functions) operating on that data. Some programming language researchers and academics use the first meaning alone or in combination with the second as a distinguishing feature of object oriented programming, while other programming languages which provide lexical closures view encapsulation as a feature of the language orthogonal to object orientation.

AMATULLHA SUMAIYA, Roll: 511127743 (BCA) SIKKIM MANIPAL UNIVERSITY, DE

The second definition is motivated by the fact that in many OOP languages hiding of components is not automatic or can be overridden; thus, information hiding is defined as a separate notion by those who prefer the second definition. Information hiding: information hiding is the principle of segregation of the design decisions in a computer program that are most likely to change, thus protecting other parts of the program from extensive modification if the design decision is changed. The protection involves providing a stable interface which protects the remainder of the program from the implementation. Written another way, information hiding is the ability to prevent certain aspects of a class or software component from being accessible to its clients, using either programming language features (like private variables) or an explicit exporting policy. Class hierarchy: An important part of object software development is the class hierarchy. The design and maintenance of such a hierarchy has been recognized as a difficult problem The difficulty increases with the size of the hierarchy and the possible evolution of the software requirements that may require the incorporation of modifications in the hierarchy. A large body of work has focused on problems related to hierarchy construction and reconstruction. Various development scenarios have been addressed such as: Building the hierarchy from scratch using: objects class specifications Evolution of requirements: the class hierarchy to accommodate new

unconstrained class addition. addition constrained by backward compatibility with a previous hierarchy or existing objects. Reengineering of an existing class hierarchy: from the relationship between classes and their attributes/methods.
AMATULLHA SUMAIYA, Roll: 511127743 (BCA) SIKKIM MANIPAL UNIVERSITY, DE 4

using code analysis tools. by applying refactorings. from UML models including associations. from access patterns in applications. prompted by detecting defects using software metrics. Q3. Describe Rumbaugh et al.s Object Modeling Technique? Answer: The object-modeling technique (OMT) is an object modeling language for software modeling and designing. It was developed circa 1991 by Rumbaugh, Blaha, Premerlani, Eddy and Lorensen as a method to develop object-oriented systems, and to support object-oriented programming. OMT was developed as an approach to software development. The purposes of modeling are: testing physical entities before building them (simulation) communication with customers visualization (alternative presentation of information) reduction of complexity.

OMT has proposed three main types of models: Object model: The object model represents the static and most stable phenomena in the modeled domain. Main concepts are classes and associations, with attributes and operations. Aggregation and generalization (with multiple inheritance) are predefined relationships. Dynamic model: The dynamic model represents a state/transition view on the model. Main concepts are states, transitions between states, and events to trigger transitions. Actions can be modeled as occurring within states. Generalization and aggregation are predefined relationships. Functional model: The functional model handles the process perspective of the model, corresponding roughly to data flow

AMATULLHA SUMAIYA, Roll: 511127743 (BCA) SIKKIM MANIPAL UNIVERSITY, DE

diagrams. Main concepts are process, data store, data flow, and actors. The entire OMT software development process has four phases: Analysis, system design, object design, and implementation of the software. Most of the modeling is performed in the analysis phase. The recommended method incorporates the following activities: a) Develop a Problem Statement. b) Build an Object Model: 1. Identify object classes. 2. Develop associations. a data dictionary for classes, attributes, and

3. Add associations between classes. 4. Add attributes for objects and links. 5. Organize and simplify object classes using inheritance. 6. Test access paths using scenarios and iterate the above steps as necessary. 7. Group classes into modules, based on close coupling and related function. c) Build a Dynamic Model: 1. Prepare scenarios of typical interaction sequences. 2. Identify events between objects and prepare an event trace for each scenario. 3. Prepare an event flow diagram for the system. 4. Develop a state diagram for each class that has important dynamic behavior. 5. Check for consistency and completeness of events shared among the state diagrams. d) Build a Functional Model: 1. Identify input and output values.

AMATULLHA SUMAIYA, Roll: 511127743 (BCA) SIKKIM MANIPAL UNIVERSITY, DE

2. Use data dependencies.

flow

diagrams

as

needed

to

show

functional

3. Describe what each function does. Identify constraints. 4. Specify optimization criteria. c) Verify, iterate, and refine the three models: 1. Add most important operations to the object model. 2. Verify that classes, associations, attributes and operations are consistent and complete, check with problem statement. 3. Iterate steps to complete the analysis.

Q4. (i) Explain about the UML language for constructing and Documenting. (ii) List few applications of UML. Answer: (i) The Unified Modeling Language (UML) is a graphical language for visualizing, specifying, constructing, and documenting the artifacts of a software-intensive system. The UML offers a standard way to write a system's blueprints, including conceptual things such as business processes and system functions as well as concrete things such as programming language statements, database schemas, and reusable software components. UML is a 'language' for specifying and not a method or procedure. The UML is used to define a software system; to detail the artifacts in the system, to document and construct - it is the language that the blueprint is written in. The UML may be used in a variety of ways to support a software development methodology such as the Rational Unified Process - but in itself it does not specify that methodology or process. The UML was designed to help the participants in software development efforts build models that enable the team to visualize the system, specify the structure and behavior of that system, construct the system, and document the decisions made along the way. Many of
AMATULLHA SUMAIYA, Roll: 511127743 (BCA) SIKKIM MANIPAL UNIVERSITY, DE 7

the tasks that the Unified Process defines involve using the UML and one or more models. Answer: (ii) UML has been used effectively in following areas: 1. Enterprise information systems. 2. Banking and financial services. 3. Telecommunications. 4. Transportation. 5. Defense. 6. Retail. 7. Medical electronics. 8. Scientific. 9. Distributed Web-based services. Modeling applications of UML using various diagrams: Structure diagrams and their applications :

Structuring diagrams show a view of an system that shows the structure of the objects, including their classifiers, relationships, attributes and operations. Behavior diagrams and their applications :

Behavior diagrams are used to illustrate the behavior of a system, they are used extensively to describe the functionality of software systems. Interaction diagrams and their applications:

Interaction diagrams are subset of behavior diagrams and emphasize the flow of control and data among the things in the system being modeled. Web applications :

1. Web applications are software-intensive systems and UML is the choice of language for modeling them. 2. Minimize software complexity of the web applications using various UML tools.
AMATULLHA SUMAIYA, Roll: 511127743 (BCA) SIKKIM MANIPAL UNIVERSITY, DE 8

3. Forms in HTML can also be modeled using various UML constructs. 4. UML can be used to express the execution of the systems business logic in those Web-specific elements and technologies.

Q5. Explain the 3 steps in extracting Entity Classes with a flowchart ? Answer: Extracting the Entity Classes performs the following 3 steps incrementally and iteratively: Functional modeling Present scenarios of all the use cases Entity Class modeling Determine the interrelationships and interactions between the entity classes Present this information in the form of a class diagram Dynamic modeling Determine the operations performed by or to each entity class Present this information in the form of a state chart Extracting the Entity Classes Step 1: Functional Modeling -- Use Cases There are two possible use cases for the elevator problem, Press an Elevator Button, and Press a Floor Button

Functional Modeling -- Use Cases

Extracting the Entity Classes Step 2: Entity Class Modeling Extract entity classes and their attributes Represent them using a UML diagram
AMATULLHA SUMAIYA, Roll: 511127743 (BCA) SIKKIM MANIPAL UNIVERSITY, DE 9

One alternative: Deduce the entity classes from use cases and their scenarios Possible danger: Many scenarios, and hence Too many candidate classes Other alternatives: CRC (Class-Responsibility-Collaboration) cards Noun extraction

The 1st Iteration of Class Diagram

The 2nd Iteration of Class Diagram

Extracting the Entity Classes Step 3: Dynamic Modeling Dynamic modeling is the third step in extracting the entity classes A statechart is constructed that reflects all the operations performed by or to the software product The operations are determined from the Scenarios

AMATULLHA SUMAIYA, Roll: 511127743 (BCA) SIKKIM MANIPAL UNIVERSITY, DE

10

Dynamic Modeling

Q6. Explain any 2 phases of Unified Process? Answer: The Unified Process is a software development process or methodology that promotes Iterative Development. The result of each iteration is an executable, but incomplete system. The system may need much iteration before it is ready for production. The Unified Process organizes work and iterations across four major phases: Inception Elaboration Construction Transition

AMATULLHA SUMAIYA, Roll: 511127743 (BCA) SIKKIM MANIPAL UNIVERSITY, DE

11

Inception phase The primary goal of the Inception phase is to establish the case for the viability of the proposed system. The tasks that a project team performs during Inception include the following: Defining the scope of the system (that is, whats in and whats out) Outlining candidate architecture, this is made up of initial versions of six different models Identifying critical risks and determining when and how the project will address them Starting to make the business case that the project is worth doing, based on initial estimates of cost, effort, schedule, and product quality The major milestone associated with the Inception phase is called LifeCycle Objectives The indications that the project has reached this milestone include the following: The major stakeholders agree on the scope of the proposed system. The candidate architecture clearly addresses a set of critical high -level requirements. The business case for the project is strong enough to justify a green light for continued development.

Elaboration Phase The primary goal of the Elaboration phase is to establish the ability to build the new system given the financial constraints, schedule constraints, and other kinds of constraints that the development project faces. The tasks that a project team performs during Elaboration include the following: Capturing a healthy majority of the remaining functional requirements

AMATULLHA SUMAIYA, Roll: 511127743 (BCA) SIKKIM MANIPAL UNIVERSITY, DE

12

Expanding the candidate architecture into a full architectural baseline, which is an internal release of the system focused on describing the architecture Addressing significant risks on an ongoing basis Finalizing the business case for the project and preparing a project plan that contains sufficient detail to guide the next phase of the project (Construction) The architectural baseline contains expanded versions of the six models initialized during the Inception phase. The major milestone associated with the Elaboration phase is called LifeCycle Architecture The indications that the project has reached this milestone include the following: Most of the functional requirements for the new system have been captured in the use case model. The architectural baseline is a small, skinny system that will serve as a solid foundation for ongoing development. The business case has received a green light, and the project team has an initial project plan that describes how the Construction phase will proceed.

AMATULLHA SUMAIYA, Roll: 511127743 (BCA) SIKKIM MANIPAL UNIVERSITY, DE

13

Das könnte Ihnen auch gefallen