Mathematical symbols
m ((username removed) (log details removed): Moving to Documentation namespace) |
(Automatically adding template at the end of the page.) |
||
Line 97: | Line 97: | ||
Tags: Equal sign, Larger than sign, Lesser than sign, Larger or equal, Less or equal | Tags: Equal sign, Larger than sign, Lesser than sign, Larger or equal, Less or equal | ||
[[Category:OCLOperators]] | [[Category:OCLOperators]] | ||
{{Edited|July|12|2024}} |
Revision as of 15:37, 10 February 2024
<> ( object : OclAny ) : Boolean
Returns true if self is a different object from object.
Expression | Result |
---|---|
let a : String = 'a', b : String = 'a' in a <> b | false |
let a : Integer = 2, b : Real = 2.0 in a <> b | false |
let a : Integer = -2, b : Integer = 2 in a <> b | true |
= ( object : OclAny) : Boolean
Returns true if self is equal to object.
Expression | Result |
---|---|
let a : String = 'a', b : String = 'a' in a = b | true |
let a : Integer = 2, b : Real = 2.0 in a = b | true |
let a : Integer = -2, b : Integer = 2 in a = b | false |
< ( object : T ) : Boolean
Returns true if self is comparable to object and less than object.
Expression | Result |
---|---|
let a : Integer = 1, b : Integer = 2 in a < b | true |
let a : Real = 1.5, b : Integer = 2 in a < b | true |
let a : String = 'Anteater', b : String = 'Aardvark' in a < b | false |
> ( object : T ) : Boolean
Returns true if self is comparable to object and greater than object.
Expression | Result |
---|---|
let a : Integer = 1, b : Integer = 2 in a > b | false |
let a : Real = 1.5, b : Integer = 2 in a > b | false |
let a : String = 'Anteater', b : String = 'Aardvark' in a > b | true |
<= ( object : T ) : Boolean
Returns true if self is comparable to object and less than or equal to object.
Expression | Result |
---|---|
let a : Integer = 1, b : Integer = 2 in a <= b | true |
let a : Real = 1.5, b : Integer = 2 in a <= b | true |
let a : String = 'Anteater', b : String = 'Aardvark' in a <= b | false |
>= ( object : T ) : Boolean
Returns true if self is comparable to object and greater than or equal to object.
Expression | Result |
---|---|
let a : Integer = 1, b : Integer = 2 in a >= b | false |
let a : Real = 1.5, b : Integer = 2 in a >= b | false |
let a : String = 'Anteater', b : String = 'Aardvark' in a >= b | true |
Tags: Equal sign, Larger than sign, Lesser than sign, Larger or equal, Less or equal
This page was edited more than 9 months ago on 03/26/2024. What links here