indexing
description: "A logging priority."
project: "Project Goanna <http://sourceforge.net/projects/goanna>"
library: "log4e"
date: "$Date$"
revision: "$Revision$"
author: "Glenn Maughan <glennmaughan@goanna.info>"
copyright: "Copyright (c) 2002 Glenn Maughan"
license: "Eiffel Forum License v1 (see forum.txt)."
class interface
L4E_PRIORITY
create
make (new_level: INTEGER; desc: STRING)
require
positive_level: new_level > 0
desc_exists: desc /= void
feature
is_equal (other: like Current): BOOLEAN
other
COMPARABLE
require ANY
other_not_void: other /= void
ensure ANY
symmetric: Result implies other.is_equal (Current)
consistent: standard_is_equal (other) implies Result
ensure then COMPARABLE
trichotomy: Result = (not (Current < other) and not (other < Current))
max (other: like Current): like Current
other
COMPARABLE
require COMPARABLE
other_exists: other /= void
ensure COMPARABLE
current_if_not_smaller: Current >= other implies Result = Current
other_if_smaller: Current < other implies Result = other
min (other: like Current): like Current
other
COMPARABLE
require COMPARABLE
other_exists: other /= void
ensure COMPARABLE
current_if_not_greater: Current <= other implies Result = Current
other_if_greater: Current > other implies Result = other
three_way_comparison (other: like Current): INTEGER
other
COMPARABLE
require COMPARABLE
other_exists: other /= void
ensure COMPARABLE
equal_zero: (Result = 0) = is_equal (other)
smaller_negative: (Result = - 1) = (Current < other)
greater_positive: (Result = 1) = (Current > other)
infix "<" (other: like Current): BOOLEAN
require PART_COMPARABLE
other_exists: other /= void
ensure then COMPARABLE
asymmetric: Result implies not (other < Current)
infix "<=" (other: like Current): BOOLEAN
other
COMPARABLE
require PART_COMPARABLE
other_exists: other /= void
ensure then COMPARABLE
definition: Result = ((Current < other) or is_equal (other))
infix ">" (other: like Current): BOOLEAN
other
COMPARABLE
require PART_COMPARABLE
other_exists: other /= void
ensure then COMPARABLE
definition: Result = (other < Current)
infix ">=" (other: like Current): BOOLEAN
other
COMPARABLE
require PART_COMPARABLE
other_exists: other /= void
ensure then COMPARABLE
definition: Result = (other <= Current)
feature
make (new_level: INTEGER; desc: STRING)
require
positive_level: new_level > 0
desc_exists: desc /= void
feature
level: INTEGER
level_str: STRING
invariant
ANY
reflexive_equality: standard_is_equal (Current)
reflexive_conformance: conforms_to (Current)
COMPARABLE
irreflexive_comparison: not (Current < Current)
end -- L4E_PRIORITY
Goanna Log4E -- Copyright © 2002 Glenn Maughan