Sybase 7.5 Water System User Manual


 
Defining operations
74
You can create two types of constructor for a given class:
Default
Copy
A Default constructor has no parameters.
Adding a Default constructor and destructor to a class
You can define only one Default constructor and one Default destructor
(PowerBuilder only) for any given class.
If the current object language of the OOM is Analysis or Java, you can create
only one Default constructor and no Default destructor for a class. The
constructor has the same name as the class to which it belongs.
If the current object language of the OOM is PowerBuilder, you can create
one Default constructor and one Default destructor for a class. The
constructor has the name "constructor" and destructor has the name
"destructor".
v To add a Default constructor and destructor to a class:
1 Double-click a class in the model.
2 Click the Operations tab.
3 Click the Add button.
4 Select Default Constructor/Destructor from the dropdown list.