OCLOperators size
(Automatically adding template at the end of the page.)
(Updated Edited template to July 12, 2025.)
 
(3 intermediate revisions by 2 users not shown)
Line 1: Line 1:
<message>Write the content here to display this box</message>
=== size () : Integer ===
=== size () : Integer ===
Returns the number of characters composing ''self''.  
Returns the number of items in a collection.  
{| class="wikitable"
{| class="wikitable"
!Expression
!Expression
!Result
!Result
|-
|-
|'size operation'.size()
|Set{1,2,4}->size()
|14
|3
|}
|}
[[Category:OCL Collection Operators]]
[[Category:OCL Collection Operators]]
{{Edited|July|12|2024}}
Not to be confused with [[Documentation:OCLOperators length|length]] that works on [[Documentation:String|strings]]
 
{{Edited|July|12|2025}}

Latest revision as of 05:58, 20 January 2025

This page was created by Alexandra on 2017-08-13. Last edited by Edgar on 2025-01-20.

size () : Integer

Returns the number of items in a collection.

Expression Result
Set{1,2,4}->size() 3

Not to be confused with length that works on strings