<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/> <title>GNU CommonC++: slogTest.cpp</title> <link href="tabs.css" rel="stylesheet" type="text/css"/> <link href="doxygen.css" rel="stylesheet" type="text/css"/> </head> <body> <!-- Generated by Doxygen 1.6.3 --> <div class="navigation" id="top"> <div class="tabs"> <ul> <li><a href="index.html"><span>Main Page</span></a></li> <li><a href="namespaces.html"><span>Namespaces</span></a></li> <li><a href="annotated.html"><span>Classes</span></a></li> <li><a href="files.html"><span>Files</span></a></li> <li><a href="examples.html"><span>Examples</span></a></li> </ul> </div> </div> <div class="contents"> <h1>slogTest.cpp</h1><div class="fragment"><pre class="fragment"> <span class="preprocessor">#include <<a class="code" href="slog_8h.html" title="System logging facilities abstraction.">cc++/slog.h</a>></span> <span class="preprocessor">#include <iostream></span> <span class="preprocessor">#include <cstdio></span> <span class="preprocessor">#ifdef CCXX_NAMESPACES</span> <span class="preprocessor"></span><span class="keyword">using namespace </span>std; <span class="keyword">using namespace </span>ost; <span class="preprocessor">#endif</span> <span class="preprocessor"></span> <span class="keywordtype">int</span> main(<span class="keywordtype">int</span> argc, <span class="keywordtype">char</span>* argv[]) { <a name="a0"></a><a class="code" href="namespaceost.html#a521e76d0861afe0b523e3c0c3956dca8">slog</a>(<span class="stringliteral">"slogTest"</span>, Slog::classUser, Slog::levelInfo); <a class="code" href="namespaceost.html#a521e76d0861afe0b523e3c0c3956dca8">slog</a> << <span class="stringliteral">"Howdy daemon and clog."</span> << endl; <a class="code" href="namespaceost.html#a521e76d0861afe0b523e3c0c3956dca8">slog</a>.<a name="a1"></a><a class="code" href="classost_1_1_slog.html#a7529ca8421ee3672a75fea37736cc94f" title="Enables or disables the echoing of the messages to clog in addition to the syslog...">clogEnable</a>(<span class="keyword">false</span>); <a class="code" href="namespaceost.html#a521e76d0861afe0b523e3c0c3956dca8">slog</a> << <span class="stringliteral">"This is only for the daemon."</span> << endl; <a class="code" href="namespaceost.html#a521e76d0861afe0b523e3c0c3956dca8">slog</a>.<a class="code" href="classost_1_1_slog.html#a7529ca8421ee3672a75fea37736cc94f" title="Enables or disables the echoing of the messages to clog in addition to the syslog...">clogEnable</a>(<span class="keyword">true</span>); <a class="code" href="namespaceost.html#a521e76d0861afe0b523e3c0c3956dca8">slog</a> << <span class="stringliteral">"Are you still there?"</span> << endl; <span class="keywordflow">return</span> 0; } </pre></div> </div> <hr class="footer"/><address style="text-align: right;"><small>Generated on Fri Mar 12 10:07:38 2010 for GNU CommonC++ by <a href="http://www.doxygen.org/index.html"> <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.6.3 </small></address> </body> </html>