Ice Default Logger usage

danleepwdanleepw Member Dan LeeOrganization: RumyourProject: Financial computing engine
Hi,

According to the Ice manual, we can enable trace log by Ice.Trace.XXX=#. Right now, I want to use the default logger to write log message. How can we use this mechanism to the application implementation? The logger interface provides:

logger->print("test print");
logger->trace("category", "test trace");
logger->warning("test warning");
logger->error("test error");

Could we set in configuration to enable only warning and error messages? or could we enable only level 1 trace message? but the method does not provide the trace level parameter? How can we identify which level of the trace message is ?

Regards,
Dan

Comments

  • benoitbenoit Rennes, FranceAdministrators, ZeroC Staff Benoit FoucherOrganization: ZeroC, Inc.Project: Ice ZeroC Staff
    Hi Dan,

    The logger implementation always prints traces, warnings and errors. It's the caller's responsibility to check for the trace level set through configuration before to call on the logger.

    Cheers,
    Benoit.
Sign In or Register to comment.