Project

General

Profile

Actions

Support #3954

open

WLogger Scope

Added by Matt Russell almost 9 years ago. Updated almost 9 years ago.

Status:
New
Priority:
Normal
Assignee:
-
Target version:
-
Start date:
04/06/2015
Due date:
% Done:

0%

Estimated time:

Description

In the [[http://www.webtoolkit.eu/wt/doc/reference/html/classWt_1_1WLogger.html#a567c5b28fee703e37523898d30016f40 the WLogger docs]] it describes setting the logger for different scopes. It uses ``wthttp`` for example.

I was wondering how I might define my own scopes? Or get a list of existing ones? Say for example I want all log entries related to the DB to go through a different scope that the default.

Actions #1

Updated by Wim Dumon almost 9 years ago

Hello Matt,

From the top of my head, the scope is just a string, so you can simply invent your own scopes. I don't know of a method that lists the scopes in use.

Best regards,

Wim.

Actions #2

Updated by Matt Russell almost 9 years ago

Wim Dumon wrote:

From the top of my head, the scope is just a string, so you can simply invent your own scopes. I don't know of a method that lists the scopes in use.

Sounds good, but how do I log to one of these? Is there any Wt::log("level", "scope") << msg

?

Actions

Also available in: Atom PDF