Introduction (Previous) (Next) PHPUnit

View this page in Last updated: Sun, 28 Sep 2008
English | French | Japanese | Plain HTML

Conversion rules

Conversion rules -- How do PHP elements map to UML?

Logical view

  • A PHP class (or interface) maps to an UML Class (or Interface).

    A PHP function maps to an UML Operation.

    A PHP property, or class constant, maps to an UML Attribute.

Packages do not exist in PHP, like they do in Java. There are two possible ways to mimic them:

  • by using the docblock @package in the comment of a class (or of a file)

    by interpreting the namespace of a class

In the latter case, PHP_UML understands the double-colon :: as the package delimiter. This works in conjunction with the PHP namespacing instructions (namespace and use).

Deployment view

  • A PHP file maps to an UML Artifact.

    A physical folder maps to an UML Package.

Component view

In UML 1.4:

  • A PHP file maps to an UML Component.

    A physical folder maps to an UML Subpackage.

In UML 2.1:

  • A PHP file maps to an UML Component.

    A physical folder maps to a nesting UML Component.

Introduction (Previous) (Next) PHPUnit

Download Documentation Last updated: Sun, 28 Sep 2008
Do you think that something on this page is wrong? Please file a bug report or add a note.
User Notes:
There are no user contributed notes for this page.