示例#1
0
std::ostream & logger::operator ()(const std::string & name, const std::string & file, int line)
{
    static std::ostringstream empty;
    auto it = _folders.find(name);
    if (it == end(_folders))
    {
        empty.setstate(std::ios::badbit);
        return empty;
    }
    auto debug_info = "(" + file + ":" + boost::lexical_cast<std::string>(line) + ") ";
    return (it->second.write_date() << debug_info);
}