UML Profile

Profile is a profile package that extends a reference metamodel (such as UML) by allowing to adapt or customize the metamodel with constructs that are specific to a particular domain, platform, or a software development method. In other words, profile is a lightweight extension mechanism to the UML standard.
A profile introduces several constraints, or restrictions, on ordinary metamodeling through the use of the metaclasses defined in this package. The primary extension construct is stereotype, which is defined as part of profile and extends some metaclass.
A profile is a restricted form of a reference metamodel that must always be related to some reference metamodel that is created from MOF such as UML or CWM. It is not possible to define a standalone profile, without its reference metamodel.
Profile uses the same notation as a package, with the addition that the keyword «profile» is shown before or above the name of the package.
Profile - 图1
Profile EJB
A profile can define classes, stereotypes, data types, primitive types, enumerations.
Profile - 图2image.png
Profile Servers
One profile might reuse some or all parts of another profile, to extend already existing profiles. Multiple profiles could be applied to the same model.
The constraints that are part of the profile are evaluated when the profile has been applied to a package. These constraints need to be satisfied in order for the model to be well-formed.
Package since UML 2.4 has optional URI attribute which serves as unique identifier of the package. Profile is a package, and the URI attribute was introduced mostly to support exchange of profiles using XMI.
The URI attribute of a profile may be rendered in the form {uri=uri} after the profile name. OMG normative profiles follow OMG normative naming scheme for URIs. For non-standard, custom profiles convention recommended by OMG looks like:
uri ::= http://**_qualified-profile-parent_** /profile-version /profile-name.xmi

  • qualified-profile-parent is the qualified name of the package containing the profile (if any), with “::” replaced by “/“ (forward slash), and all other illegal XML QName characters removed. For example: www.uml-diagrams.org/profiles.
  • profile-version is a profile version id. OMG normative profiles use for this purpose date in the format YYYYMMDD, for example: 20110331.
  • profile-name is the name of the profile, should contain only valid XML QName characters. For example: ejb-30.

Note, that UML specification here mingled two different specifications. The whole URI value should follow obsolete URI specification RFC 2396 (see: URI package attribute), while qualified-profile-parent part should also be (or will be made) valid XML QName. XML QName usually has namespace prefix followed by ‘:’, e.g. ‘taxes:dependent’, which contradicts to the URI requirement.
Profile - 图4
EJB Profile shown as a package with URI attribute.

https://www.uml-diagrams.org/profile.html