1 Apr 01:43
Re: Boost Logging library - first draft
Gareth Buxton <gareth.buxton <at> googlemail.com>
2007-03-31 23:43:21 GMT
2007-03-31 23:43:21 GMT
Hi Jean Daniel I also have been working on a logger and have been considering proposing it for inclusion in boost. I feel that a logger must be both simple and a natural extension of the standard stream libraries. Essentially everything should be a stream. A logger then is merely a facilitator for managing streams of messages generated by a piece of software. So if you want to send some of your logging output to a file you might attach a std::fstream to the logger. If you want to sent your output over a network you might attack a socket_stream to the logger. So basically the logger manages the aggregation of various streams of information. In addition to this the logger must enable a certain amount of control over these aggregate streams. Traditionally this is managed by masking off one or more streams when their output is not desired. The other form of control the logger would need to exert over the data itself would be formatting information. Each logging event will capture a definite amount of data at a given point in program execution. This data would typically be time, date, message etc. The logger should not format this data itself as that would be too restrictive on the desired output. Rather the logger should be able to accept a formatting object to do this job appropriately to the given task.(Continue reading)
RSS Feed