is a general template that we use to create specific instances, or objects, in the problem domain. All objects of a given class are identical in structure and behavior but contain different data in their attributes. There are two general kinds of classes of interest during analysis: concreter and abstract.
A second classification of classes is the type of real-world thing that a class represents. There are domain classes, user-interface classes, data structure classes, file structure classes, operating environment classes, document classes, and various types of multimedia classes.
An attribute of an analysis class represents a piece of information that is relevant to the description of the class within the application domain of the problem being investigated An attribute contains information the analyst or user feels the system should keep track of. Example: a possible relevant attribute of an employee class is employee name, whereas on that might not be as relevant is hair color.
There are 3 types of relationships categories of data abstraction mechanisms: generalization relationships, aggregation relationships, and association relationships.
CRC (class-responsibility-collaboration) cards are used to document the responsibilities and collaboration of a class. In some object-oriented systems-development methodologies, CRC cards are seen to be an alternative competitor to the Unified Process employment of uses cases and class diagrams.
Responsibilities of a class can be broken into two separate types: knowing and doing. Knowing are those things that an instance of a class must can know. Doing responsibilities are those things that an instance of a class must can do.
Elements of a CRC Card, a set of CRC cards contain all the information necessary to build a logical structural model of the problem under investigation. CRC card captures and describes the essential elements a class. The front of the card contains the class’s name, ID, type description, associated use cases, responsibilities and collaborators. The name of a class should be a noun (but not a proper noun, such as the name of specific person or thing).
can be used in a role-playing exercise that has been shown to be useful in discovering additional objects, attributes, relationships and operations. In addition to walkthroughs, role-playing is very useful in testing the fidelity of the evolving structural model.
step in in use-case is to review, this allows the team to pick a specific use case to role-play. 2nd
step is the identify the relevant roles that are to be played. Each role is associated with either an actor or an object. To choose the relevant objects, the team reviews each of the CRC cards and picks the ones that are associated with the chosen use case. 3Rd
step is to role-play scenarios of the use case by having the team members perform each one. To do this, each team member must pretend that he or she is an instance of the role assigned to him or her. 4th
step is to simply repeat steps 1 through 3 for the remaining use cases.
There are two types of design criteria, coupling which refers to how interdependent or interrelated the modules (classes, objects, and methods) are in a system. 2nd
type is cohesion which refers to how single-minded a module (class, object, or method) is within a system. A class or object should represent only one thing, and a method should solve only an object-oriented system: class and generalization/specialization.
generalizes the ideas of cohesion and coupling, and it combines them with the arguments of for encapsulation. There 5 types of connoascence.
Algorithm is a type of connascence, described as two different methods of a class are dependent on the same algorithm to execute correctly (e.g., insert an element into an array and find an element in the same array). If the underlying algorithm would change, then the insert and find methods would also have to change.
Object Constraint Language (OCL)
is a complete language designed to specify constraints. All OCL expressions are simply a declarative statement that evaluates to either being true or false. If the expression evaluates is true, the constraints has been satisfied. OCL provides many others constrains that can be used to build unique constraints. To include math-oriented operators, string operators, and relationships traversal operators. OCL provides a set of operations that are used to support constraints over a collection of objects. And provides a rich set of operators and operations in which to model constraints. Operators Types are: Comparison, Logical, Math, String Relationship Traversal, and collection.
Elements of a contract, contracts document the message passing that take place between objects. A contract should be created for each message sent and received by each object, one for each interaction. A contract is created for each method that can receive messages from other objects (i.e., one for each visible method). Contract should contain the information necessary for a programmer to understand what a method is to do. This information should include method name, class name, ID number, client objects, associated use cases, description, arguments received, type of data returned, and the pre- and postconditions. Contracts do have a detailed algorithm description of how the method is to work.
“A Real Estate Incorporation name AREI, sells houses. People who want to sell their houses sign a contract with AREI and provide information on their house. This information is kept in database by AREI, and a subset of this information is sent to the citywide multiple-listing service used by all real estate agents AREI works with two types of potential buyers. Some buyers have an interest in one specific house. In this case, AREI prints information from its database, which the real estate agent uses to help show the house to the buyer (a process beyond the scope of the system to be molded). Other buyers seek AREI’s advice in finding a house that meets their needs. In this case, the buyer completes a buyer information form that is entered into a buyer database and AREI real estate agents use its information to search AREI’s database and the multiple-listing service for houses that meet their needs. The results of these searches are printed and used to help the real estate agent show houses to the buyer. “
1) Choose one of the classes and create a set of invariants for attributes and relationships and add them to the CRC card for the class.
2. Choose one of the methods in the class that you chose and create a contract and a method specification for it. Use OCL to specify any pre- or postcondition and use both Structured English and an activity diagram to specify the algorithm.
NO Plagiarisms, in APA format, and include reference page!!!!!!!!!