How to create Singleton Objects with ports in Rational Rhapsody

Technote (FAQ)


Question

How do you create Singleton Objects in IBM Rational Rhapsody ?

Cause

You want to restrict the instantiation of a class to just one object which contains a port.

Answer

Procedure:

  1. Create class in the project

  2. Apply the stereotype Singleton on it

  3. Add a port to the class

  4. Make an object (Right click on class > Make an Object)

  5. Generate code

Rate this page:

(0 users)Average rating

Add comments

Document information


More support for:

Rational Rhapsody
General Information

Software version:

7.6.1.1, 7.6.1.2, 7.6.1.3, 8.0, 8.0.1, 8.0.2

Operating system(s):

Linux, Windows

Reference #:

1633263

Modified date:

2013-04-19

Translate my page

Machine Translation

Content navigation