|
Boost : |
From: Manuel Jung (gzahl_at_[hidden])
Date: 2008-04-03 05:01:24
Hey John,
You said, you would show me the next day latest, but you didn't. Can i
kindly ask, if you are still willing to help?
Thanks,
Manu
> Hi Manuel,
>
> I will show you how to do it tomorrow the latest.
>
> Best,
> John
>> Hi,
>>
>> I would like to log to a standard container like std::list<std::string>
>> or something similar, so i can send my logs to another program over
>> network. But i have problems defining my own destination. For now it
>> would be ok, to log just to a string. But i don't understand how to
>> define my own destination in the right way. I looked at
>>
http://torjo.com/log2/doc/html/namespaceboost_1_1logging_1_1manipulator.html#manipulator_create
>> but i don't understand the "sharing data" part well. Maybe someone can
>> help me out here?
>>
>> I have so far:
>> struct to_string : boost::logging::destination::class_<to_string,
>> boost::logging::destination::implement_op_equal::has_context> {
>> std::string s;
>> to_string(std::string s) : s(s) {}
>>
>> bool operator==(const to_string& other) { return s == other.s; }
>>
>> // param = const std::string&
>> // (in other words, it's the arg_type from your destination base
>> class) void operator()(param msg) const {
>> // s.append(msg);
>> }
>>
>> But even that is not compiling. Any help would be appreciated! :-)
>> Greetings
>> Manuel Jung
>>
>> _______________________________________________
>> Unsubscribe & other changes:
>> http://lists.boost.org/mailman/listinfo.cgi/boost
>>
>>
>
>
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk