Please post support and help requests here.
Posts: 4
Joined: 11 Dec 2012, 20:00


Postby vonkanaitor » 31 Dec 2012, 12:36

Code: Select all

AutoPtr<ConsoleChannel> pCons(new ConsoleChannel);
   AutoPtr<PatternFormatter> PatternForm(new PatternFormatter);
   PatternForm->setProperty("pattern", "%Y-%m-%d %H:%M:%S %s: %t");
   AutoPtr<FormattingChannel> pFC(new FormattingChannel(PatternForm, pCons));
   AutoPtr<FileChannel>pFileChan(new FileChannel("Arc.log"));
   AutoPtr<FormattingChannel>pFFC(new FormattingChannel(PatternForm, pFileChan));
   AutoPtr<SplitterChannel> sLog(new SplitterChannel);
   //Logger& pLog = Logger::create("ConsoleChannel", sLog, Message::PRIO_INFORMATION);

Ive tried and failed. How do i do it properly and also, how can i use this Logger throughout my entire server, or will i have to create a new Logger each time?

Posts: 4
Joined: 11 Dec 2012, 20:00

Re: Logger

Postby vonkanaitor » 02 Jan 2013, 00:17

Ive fixed my logging system. However, how can i access it from multiple classes; this is probably very basic but i think ive missed a few lessons XD

Return to “Support”

Who is online

Users browsing this forum: guenter and 4 guests