Chapter 2 Building an Object-Oriented Model

A copy of the operation is added to the list operations for the class.

Adding Getter and Setter operations to a class

Getter or a Setter operations are special types of operations that you create for an attribute. You create a Getter or a Setter operation type from the list of attributes of a class. For each attribute, you can create one Getter, one Setter operation, or both a Getter and a Setter operation.

You create Getter or a Setter operations for sending a receiving data values between fields.

Operation

Getter

Setter

Description

Returns a value from a field

Puts a value into a field

ϖTo add a Getter and a Setter operation to a class from an attribute:

1Double-click a class in the model. The class property sheet appears.

2Click the Attributes tab. The Attributes page appears.

3Select one or more attributes.

79

Page 89
Image 89
Sybase 7.5 manual Adding Getter and Setter operations to a class, Operation