Adding Getter and Setter Operations to a Classifier

PowerDesigner helps you to quickly create Getter and Setter operations for your attributes from the Attributes tab of your classifier.

  1. Open the property sheet of your classifier and click the Attributes tab.


  2. Select one or more attributes and then click the Add button at the bottom of the attributes tab and select the action you want to perform. Depending on the target language, some of the following actions will be available:
    • Get/Set Operations - Creates get and set operations on the Operations tab for the selected attributes
    • Property - [C#/VB.NET only] Creates a property on the Attributes tab and get and set operations on the Operations tab to access the original attribute via the property.
    • Indexer - [C# only] Creates an indexer on the Attributes tab and get and set operations on the Operations tab to access the original attribute via the indexer.
    • Event Operations - [C#/VB.NET only, for attributes with the Event stereotype] Creates add and remove operations on the Operations tab for the event.
  3. [optional] Click the Operations tab to view the newly created operations. Certain values, including the names cannot be modified.
  4. Click OK to close the property sheet and return to your model.