Chapter 2 Building an Object-Oriented Model

Defining operations

An operation is a service that can be requested from an object to effect behavior. It has a name and a list of parameters. An operation is a specification of a transformation or query that an object may be called to execute.

Operation names within a class must be unique. You can give identical names to two or more operations only if they exist in different classes.

Operation properties

An operation has the following properties:

Property

Parent

Name

Code

Comment

Stereotype

Return Type

Visibility

Event

Abstract

Final

Static

Description

Object to which the operation belongs to

Name of the operation

Reference name for the operation

Descriptive comment for the operation

Subclassification of an operation derived from an existing one. Extends the semantics of an operation without changing it's structure

A list of values returned by a call of the operation. If there are no values returned by the operation, the return type value is null

Visibility of the operation, whose value denotes how it may be seen outside its enclosing name space

Significant occurrence that has a location in time and space. An event can trigger a state transition

Indicates that the operation cannot be instantiated and therefore has no direct instances

Indicates that the operation cannot be redefined

Defines the operation as static, meaning it cannot be modified

Maximum length

254

254

254

An operation definition also includes business rules, and parameters, which are defined on associated property sheets.

67

Page 77
Image 77
Sybase 7.5 manual Defining operations, Operation properties, An operation has the following properties