Ice.Logger

class Ice.Logger

Bases: ABC

The Ice message logger.

Applications can provide their own logger by implementing this interface and installing it in a communicator.

abstractmethod cloneWithPrefix(prefix: str) Logger

Return a clone of the logger with a new prefix.

Parameters:

prefix (str) – The new prefix for the logger.

Returns:

A new logger instance with the specified prefix.

Return type:

Logger

abstractmethod error(message: str)

Log an error message.

Parameters:

message (str) – The error message to log.

abstractmethod getPrefix() str

Get this logger’s prefix.

Returns:

The prefix of this logger.

Return type:

str

abstractmethod print(message: str)

Print a message.

The message is printed literally, without any decorations such as executable name or timestamp.

Parameters:

message (str) – The message to log.

abstractmethod trace(category: str, message: str)

Log a trace message.

Parameters:
  • category (str) – The trace category.

  • message (str) – The trace message to log.

abstractmethod warning(message: str)

Log a warning message.

Parameters:

message (str) – The warning message to log.