updated documentation

[SVN r15046]
This commit is contained in:
Jeff Garland
2002-08-22 00:11:01 +00:00
parent 65425b526f
commit b22d572c70
33 changed files with 3378 additions and 0 deletions

View File

@@ -0,0 +1,40 @@
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html><head><meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1">
<title>Example Documentation</title>
<link href="doxygen.css" rel="stylesheet" type="text/css">
</head><body bgcolor="#ffffff">
<!-- Generated by Doxygen 1.2.10 -->
<hr><h1>time_math.cpp</h1> Various types of calculations with times and time durations.
<p>
<div class="fragment"><pre><font class="comment">//Some simple examples of constructing and calculating with times</font>
<font class="comment">//Output:</font>
<font class="comment">//2002-Feb-01 00:00:00 - 2002-Feb-01 05:04:02.001000000 = -5:04:02.001000000</font>
<font class="preprocessor">#include "boost/gdtl/posix_time/posix_time.hpp"</font>
<font class="preprocessor">#include &lt;iostream&gt;</font>
<font class="keywordtype">int</font>
main()<font class="keyword"> </font>
<font class="keyword"></font>{
<font class="keyword">using</font> <font class="keyword">namespace </font>boost::posix_time;
<font class="keyword">using</font> <font class="keyword">namespace </font>boost::gregorian;
date d(2002,Feb,1); <font class="comment">//an arbitrary date</font>
<font class="comment">//construct a time by adding up some durations durations</font>
ptime t1(d, hours(5)+minutes(4)+seconds(2)+millisec(1));
<font class="comment">//construct a new time by subtracting some times</font>
ptime t2 = t1 - hours(5)- minutes(4)- seconds(2)- millisec(1);
<font class="comment">//construct a duration by taking the difference between times</font>
time_duration td = t2 - t1;
std::cout &lt;&lt; to_simple_string(t2) &lt;&lt; <font class="stringliteral">" - "</font>
&lt;&lt; to_simple_string(t1) &lt;&lt; <font class="stringliteral">" = "</font>
&lt;&lt; to_simple_string(td) &lt;&lt; std::endl;
<font class="keywordflow">return</font> 0;
}
</pre></div><hr><address><small>
Generated Wed Mar 13 13:38:03 2002 by <a href="http://www.doxygen.org">Doxygen</a> for <a href="http://www.crystalclearsoftware.com">CrystalClear Software</a>&nbsp;&copy 2000-2002</small></address>
</body>
</html>