OCLOperators nullValue
m ((username removed) (log details removed): Moving to Documentation namespace)
(Replacing message template with parser tag)
 
(2 intermediate revisions by the same user not shown)
Line 1: Line 1:
<message>Write the content here to display this box</message>
A typed null value, used to assign a null value to an attribute, a variable or return null from a method.  
A typed null value, used to assign a null value to an attribute, a variable or return null from a method.  
  someobject.someattribute := <Type>.nullValue
  someobject.someattribute := <Type>.nullValue
Line 5: Line 6:
For comparing to null, use the operators [[OCLOperators isNull|.isNull]] or [[OCLOperators notNull|.notNull]]
For comparing to null, use the operators [[OCLOperators isNull|.isNull]] or [[OCLOperators notNull|.notNull]]
[[Category:OCL General Operators]]
[[Category:OCL General Operators]]
{{Edited|July|12|2024}}

Latest revision as of 07:51, 17 June 2024

A typed null value, used to assign a null value to an attribute, a variable or return null from a method.

someobject.someattribute := <Type>.nullValue

Do not use <Type>.nullValue to compare something to null, like this

vCurrent_UppdragTyp = Uppdragstyp.nullValue    -- WRONG

For comparing to null, use the operators .isNull or .notNull

This page was edited 94 days ago on 06/17/2024. What links here