indexing
description: "Logging logger."
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_LOGGER
create
make (hierarchy: L4E_HIERARCHY; cat_name: STRING)
require
cat_name_exists: cat_name /= void
ensure
context_set: context = hierarchy
name_set: name = cat_name
additive: is_additive
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
other
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
Debug_int: INTEGER is 10000
L4E_PRIORITY_CONSTANTS
debug_p: L4E_PRIORITY
L4E_PRIORITY_CONSTANTS
Error_int: INTEGER is 40000
L4E_PRIORITY_CONSTANTS
error_p: L4E_PRIORITY
L4E_PRIORITY_CONSTANTS
Fatal_int: INTEGER is 50000
L4E_PRIORITY_CONSTANTS
fatal_p: L4E_PRIORITY
L4E_PRIORITY_CONSTANTS
Info_int: INTEGER is 20000
L4E_PRIORITY_CONSTANTS
info_p: L4E_PRIORITY
L4E_PRIORITY_CONSTANTS
Warn_int: INTEGER is 30000
L4E_PRIORITY_CONSTANTS
warn_p: L4E_PRIORITY
L4E_PRIORITY_CONSTANTS
feature
debugging (message: ANY)
require
message_exists: message /= void
error (message: ANY)
require
message_exists: message /= void
fatal (message: ANY)
require
message_exists: message /= void
info (message: ANY)
require
message_exists: message /= void
log (event_priority: L4E_PRIORITY; message: ANY)
require
event_priority_exists: event_priority /= void
message_exists: message /= void
warn (message: ANY)
require
message_exists: message /= void
feature
appenders: DS_LINKED_LIST [L4E_APPENDER]
context: L4E_HIERARCHY
is_additive: BOOLEAN
is_enabled_for (check_priority: L4E_PRIORITY): BOOLEAN
require
check_priority_exists: check_priority /= void
ensure
true_if_priority_enabled: Result = (context.disabled < check_priority.level and priority <= check_priority)
is_priority_set: BOOLEAN
name: STRING
parent: L4E_LOGGER
priority: L4E_PRIORITY
feature
add_appender (new_appender: L4E_APPENDER)
require
new_appender_exists: new_appender /= void
not_added: not appenders.has (new_appender)
ensure
appender_added: appenders.has (new_appender)
call_appenders (event: L4E_EVENT)
require
event_exists: event /= void
close_appenders
remove_appender (appender_name: STRING)
require
name_exists: appender_name /= void
set_additive (flag: BOOLEAN)
set_priority (new_priority: L4E_PRIORITY)
require
priority_exists: new_priority /= void
invariant
name_exists: name /= void and then not name.is_empty
appenders_exist: appenders /= void
ANY
reflexive_equality: standard_is_equal (Current)
reflexive_conformance: conforms_to (Current)
COMPARABLE
irreflexive_comparison: not (Current < Current)
end -- L4E_LOGGER
Goanna Log4E -- Copyright © 2002 Glenn Maughan