Visual Basic 2005 Namespaces

Namespaces restrict the scope of an object's name. Each class or other type must have a unique name within the namespace.

PowerDesigner models namespaces as standard packages with the Use Parent Namespace property deselected. For information about creating and working with packages, see Packages (OOM).

In the following example, class Architect is declared in package Design which is a sub-package of Factory. The namespace declaration is the following:

Namespace Factory.Design
 Public Class Architect
...
...End Class
End Namespace ' Factory.Design

This structure, part of the NewProduct model, appears in the PowerDesigner Browser as follows:



Classifiers defined directly at the model level fall into the Visual Basic 2005 global namespace.