testPriority.cpp
Go to the documentation of this file.
00001 #include <iostream>
00002 #include "log4cpp/Priority.hh"
00003 
00004 using namespace log4cpp;
00005 
00006 int main(int argc, char** argv) {
00007     
00008     std::cout << "priority debug(700): " << Priority::getPriorityName(700) << std::endl;
00009     std::cout << "priority debug(700): " << Priority::getPriorityValue("DEBUG") << std::endl;
00010     std::cout << "priority debug(700): " << Priority::getPriorityValue("700") << std::endl;
00011     try {
00012         std::cout << "priority debug(700): " << Priority::getPriorityValue("700arghh") << std::endl;
00013     } catch(std::invalid_argument& e) {
00014         std::cout << "caught " << e.what() << std::endl;
00015     }
00016     return 0;
00017 }


log4cpp
Author(s): Stephen Roderick, Bastiaan Bakker, Cedric Le Goater, Steve Ostlind, Marcel Harkema, Walter Stroebel, Glenn Scott and Tony Cheung.
autogenerated on Wed Sep 16 2015 10:27:14