In UML models, you can specify the language that is used to write the body of a constraint so that others who read the constraint can more easily understand its condition or restriction. The body can be written using a variety of languages, including natural languages such as English, programming languages such as Java™, a mathematical notation, or the Object Constraint Language (OCL). For more information about OCL, read the Unified Modeling Language 2.0 Superstructure specification that is available on the Object Management Group (OMG) Web site.
Parent topic: Using stereotypes and constraints to extend the meaning of model elements
Related concepts
Constraints
Related information
UML Resource Center on IBM developerWorks