indexing
description: "Temporal intervals"
status: "See notice at end of class"
date: "$Date$"
revision: "$Revision$"
deferred class interface
DURATION
feature
zero: like Current
GROUP_ELEMENT
ensure GROUP_ELEMENT
result_exists: Result /= void
feature
infix "<" (other: like Current): BOOLEAN
other
PART_COMPARABLE
require PART_COMPARABLE
other_exists: other /= void
infix "<=" (other: like Current): BOOLEAN
other
PART_COMPARABLE
require PART_COMPARABLE
other_exists: other /= void
infix ">" (other: like Current): BOOLEAN
other
PART_COMPARABLE
require PART_COMPARABLE
other_exists: other /= void
infix ">=" (other: like Current): BOOLEAN
other
PART_COMPARABLE
require PART_COMPARABLE
other_exists: other /= void
feature
is_negative: BOOLEAN
is_positive: BOOLEAN
is_zero: BOOLEAN
feature
prefix "+": like Current
ensure GROUP_ELEMENT
result_exists: Result /= void
result_definition: Result.is_equal (Current)
infix "-" (other: like Current): like Current
other
require GROUP_ELEMENT
other_exists: other /= void
ensure GROUP_ELEMENT
result_exists: Result /= void
feature
infix "+" (other: like Current): like Current
other
GROUP_ELEMENT
require GROUP_ELEMENT
other_exists: other /= void
ensure GROUP_ELEMENT
result_exists: Result /= void
commutative: Result.is_equal (other + Current)
prefix "-": like Current
GROUP_ELEMENT
ensure GROUP_ELEMENT
result_exists: Result /= void
result_definition: (Result + Current).is_equal (zero)
invariant
sign_correctness: is_positive xor is_negative xor is_zero
ANY
reflexive_equality: standard_is_equal (Current)
reflexive_conformance: conforms_to (Current)
GROUP_ELEMENT
neutral_addition: Current.is_equal (Current + zero)
self_subtraction: zero.is_equal (Current - Current)
end -- DURATION