: Public abstract Interface
Created: 23.5.2022 18.05.03
Modified: 1.8.2022 13.54.00
Project:
Advanced:
A sequence is a type of set where the elements have been assigned offsets (a integral ordering). If the same element is assigned multiple offsets, then the sequence "revisits" the element for each assigned offset.  Logically, we can think of a sequence as a set of pairs #lt;element :T, offset : Integer#gt;. Since both element and offset must be equal for the ordered pair to be equal, there is no violation of the set semantics.  Not all numbered slots in a sequence must be occupied, and no offset may be occupied that exceeds the "length." <br/><br/>{offset #gt; length implies element.isNull}<br/>
Attribute
Public Integer
  length
Details:
 
Operation
Public
append( element: T,
):Sequence<T>
Details:
Sequential
Public
asSet():Set<T>
Details:
Sequential
Public
at( position: Integer,
):T
Details:
Sequential
Public
collect( expr: OCL,
):Sequence<expr.type>
Details:
Sequential
Public
concatenate( tail: Sequence<T>,
):Sequence<T>
Details:
Sequential
Public
deleteAt( position: Integer,
):Sequence<T>
Details:
Sequential
Public
deleteFirst():Sequence<T>
Details:
Sequential
Public
deleteLast():Sequence<T>
Details:
Sequential
Public
first():Record<T, Integer = 1>
Details:
Sequential
Public
last():Record<T, Integer = length>
Details:
Sequential
Public
prepend( element: T,
):Sequence<T>
Details:
Sequential
Public
reverse():Sequence<T>
Details:
Sequential
Public
subSequence( begin: Integer,
end: Integer,
):Sequence<T>
Details:
Sequential
Public
tail():Sequence<T>
Details:
Sequential
Element Source Role Target Role
T
Class  
Name: element
 
Name:  
 
Details:
 
Tag Value
persistence persistent
Details:
 
Property Value
isFinalSpecialization: 0
Object Type Connection Direction Notes
CircularSequence Interface Generalization From  
Collection Interface Generalization To