Object and Class

1) Object and Class
Class is template to create objects and represents classification of objects such as Employee, which is a class for the objects such as “Tom”, “Joe”, “Hanako”

2) OO-Analysis
            - Break the requirements into smaller problems (decompose the requirements)
            - Try to understand “WHAT” is require instead of “HOW” to implement
- Create conceptual domain model (only consider domain specific objects
   and  not system specific)

Such as in case of  our “Online Banking System” (OBS) Project following is a conceptual design (domain model)

3) OO-Design
o   For each identified object find out how they will cooperate and collaborate with each other to understand the relationship between them.

o   Then assign responsibility by adding properties and methods (behavior) to each object

o   Add helper objects (system specific and not business specific)
Such as TransactionManager

4) OO-Implementation:
o   Implement the design using specific OO Language, such as Java
-       Create new project in eclipse : OnlineBankingSystem
o   Create class : Customer

public class Customer {
       private String lastName;
       private String firstName;

       public String getLastName() {
              return lastName;
       }
       public void setLastName(String lastName) {
              this.lastName = lastName;
       }
       public String getFirstName() {
              return firstName;
       }
       public void setFirstName(String firstName) {
              this.firstName = firstName;
       }
}

No comments :

Post a Comment