Chapter 4 Managing Profiles


Defining a Custom Check in a Profile

You can add custom checks on concrete and abstract metaclasses, however, custom checks are only relevant on modeling metaclasses (for example business rules); they should not be defined on technical objects like symbols or report items.

For more information on concrete and abstract metaclasses, see the "PowerDesigner Public Metamodel" chapter.

You create custom checks using the Visual Basic scripting language.

For more information on the Visual Basic Scripting language, see the "Accessing objects using VBScript" chapter in the General Features Guide .

Custom checks can be defined on a metaclass and also for a stereotype or a criterion.

When you define a check on a metaclass It applies to all instances of the selected metaclass. The custom checks defined on an abstract metaclass appear in all its children categories in the Check Model dialog box. For example, you define a check on the metaclass Classifier, this check will appear in the Class and Interface categories.

When you define a check on a stereotype or a criterion It allows you to bind the custom check to a certain stereotype or criterion condition: if the object has the correct stereotype or meets a condition, then PowerDesigner will invoke the custom check during the check model process.

Several custom checks can be added to a given metaclass, they will all appear in the Check Model Parameters dialog box where you can modify their severity or auto-fix parameters.

 


Copyright (C) 2005. Sybase Inc. All rights reserved.