CSC/ECE 517 Fall 2010/ch1 S6 CC: Difference between revisions

From Expertiza_Wiki
Jump to navigation Jump to search
No edit summary
No edit summary
Line 11: Line 11:
'''Class Name'''
'''Class Name'''


In real world there are many individual objects of the same kind. There may be many cars of the same make and model. Each car might have been built using the same design making use of similar parts. All such cars belong to the same class known as cars and each car is an instance of the class cars.  
The class name usually represents a noun such as a person or a place name. For example, lets consider a class named cars. All the objects belonging to the class cars are built using the same design making use of similar parts. In real world there are many individual objects of the same kind. So, while


Class Responsibilities
Class Responsibilities
Collaborators
Collaborators

Revision as of 23:03, 5 September 2010

Usually most of the real world problems are large, complex and less well defined. Therefore the analysis and refinement of design would be a longer and complex process. As our problem becomes large and complicated, it is unlikely that our initial designs are perfect. Therefore it is a good practice to repeatedly check these initial designs and make necessary changes before we can convert these into final ones. One way of refining our initial designs is by using CRC cards.

Introduction

CRC stands for Class Responsibility Collaborator.CRC card modeling is one of the prominent Object Oriented Design Technique. This technique is used in determining the various classes, their functionalities and their collaborations in the software system.Class-Responsibility-Collaboration cards have been first introduced by Kent Beck and Ward Cunningham in their paper "A Laboratory for teaching Object-Oriented Thinking". CRC cards are used to document all the classes and their collaboration with the other classes in the system. This helps us in the process of designing a flawless system. This is also a cheap way of designing a system. Not just one but multiple designers can work together in designing a system using CRC cards modeling technique.

Structure of a CRC card

CRC card consists of three parts.

Class Name

The class name usually represents a noun such as a person or a place name. For example, lets consider a class named cars. All the objects belonging to the class cars are built using the same design making use of similar parts. In real world there are many individual objects of the same kind. So, while

Class Responsibilities Collaborators