Imported Upstream version 1.64.0
[platform/upstream/boost.git] / libs / log / doc / html / boost / log / sinks / file / rotation_at_time_point.html
1 <html>
2 <head>
3 <meta http-equiv="Content-Type" content="text/html; charset=US-ASCII">
4 <title>Class rotation_at_time_point</title>
5 <link rel="stylesheet" href="../../../../../../../../doc/src/boostbook.css" type="text/css">
6 <meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
7 <link rel="home" href="../../../../index.html" title="Chapter&#160;1.&#160;Boost.Log v2">
8 <link rel="up" href="../../../../sinks.html#header.boost.log.sinks.text_file_backend_hpp" title="Header &lt;boost/log/sinks/text_file_backend.hpp&gt;">
9 <link rel="prev" href="collector.html" title="Struct collector">
10 <link rel="next" href="rotation_at_time_interval.html" title="Class rotation_at_time_interval">
11 </head>
12 <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
13 <table cellpadding="2" width="100%"><tr><td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../../../boost.png"></td></tr></table>
14 <hr>
15 <div class="spirit-nav">
16 <a accesskey="p" href="collector.html"><img src="../../../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../../../../sinks.html#header.boost.log.sinks.text_file_backend_hpp"><img src="../../../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="rotation_at_time_interval.html"><img src="../../../../../../../../doc/src/images/next.png" alt="Next"></a>
17 </div>
18 <div class="refentry">
19 <a name="boost.log.sinks.file.rotation_at_time_point"></a><div class="titlepage"></div>
20 <div class="refnamediv">
21 <h2><span class="refentrytitle">Class rotation_at_time_point</span></h2>
22 <p>boost::log::sinks::file::rotation_at_time_point</p>
23 </div>
24 <h2 xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="refsynopsisdiv-title">Synopsis</h2>
25 <div xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="refsynopsisdiv"><pre class="synopsis"><span class="comment">// In header: &lt;<a class="link" href="../../../../sinks.html#header.boost.log.sinks.text_file_backend_hpp" title="Header &lt;boost/log/sinks/text_file_backend.hpp&gt;">boost/log/sinks/text_file_backend.hpp</a>&gt;
26
27 </span>
28 <span class="keyword">class</span> <a class="link" href="rotation_at_time_point.html" title="Class rotation_at_time_point">rotation_at_time_point</a> <span class="special">{</span>
29 <span class="keyword">public</span><span class="special">:</span>
30   <span class="comment">// types</span>
31   <span class="keyword">typedef</span> <span class="keyword">bool</span> <a name="boost.log.sinks.file.rotation_at_time_point.result_type"></a><span class="identifier">result_type</span><span class="special">;</span>
32
33   <span class="comment">// <a class="link" href="rotation_at_time_point.html#boost.log.sinks.file.rotation_at_time_pointconstruct-copy-destruct">construct/copy/destruct</a></span>
34   <span class="keyword">explicit</span> <a class="link" href="rotation_at_time_point.html#idp65095456-bb"><span class="identifier">rotation_at_time_point</span></a><span class="special">(</span><span class="keyword">unsigned</span> <span class="keyword">char</span><span class="special">,</span> <span class="keyword">unsigned</span> <span class="keyword">char</span><span class="special">,</span> <span class="keyword">unsigned</span> <span class="keyword">char</span><span class="special">)</span><span class="special">;</span>
35   <span class="keyword">explicit</span> <a class="link" href="rotation_at_time_point.html#idp65100176-bb"><span class="identifier">rotation_at_time_point</span></a><span class="special">(</span><span class="identifier">date_time</span><span class="special">::</span><span class="identifier">weekdays</span><span class="special">,</span> <span class="keyword">unsigned</span> <span class="keyword">char</span> <span class="special">=</span> <span class="number">0</span><span class="special">,</span> 
36                                   <span class="keyword">unsigned</span> <span class="keyword">char</span> <span class="special">=</span> <span class="number">0</span><span class="special">,</span> <span class="keyword">unsigned</span> <span class="keyword">char</span> <span class="special">=</span> <span class="number">0</span><span class="special">)</span><span class="special">;</span>
37   <span class="keyword">explicit</span> <a class="link" href="rotation_at_time_point.html#idp65106896-bb"><span class="identifier">rotation_at_time_point</span></a><span class="special">(</span><span class="identifier">gregorian</span><span class="special">::</span><span class="identifier">greg_day</span><span class="special">,</span> <span class="keyword">unsigned</span> <span class="keyword">char</span> <span class="special">=</span> <span class="number">0</span><span class="special">,</span> 
38                                   <span class="keyword">unsigned</span> <span class="keyword">char</span> <span class="special">=</span> <span class="number">0</span><span class="special">,</span> <span class="keyword">unsigned</span> <span class="keyword">char</span> <span class="special">=</span> <span class="number">0</span><span class="special">)</span><span class="special">;</span>
39
40   <span class="comment">// <a class="link" href="rotation_at_time_point.html#idp65093184-bb">public member functions</a></span>
41   <span class="keyword">bool</span> <a class="link" href="rotation_at_time_point.html#idp65093744-bb"><span class="keyword">operator</span><span class="special">(</span><span class="special">)</span></a><span class="special">(</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span>
42 <span class="special">}</span><span class="special">;</span></pre></div>
43 <div class="refsect1">
44 <a name="idp127367760"></a><h2>Description</h2>
45 <p>The class represents the time point of log file rotation. One can specify one of three types of time point based rotation:</p>
46 <div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; ">
47 <li class="listitem"><p>rotation takes place every day, at the specified time </p></li>
48 <li class="listitem"><p>rotation takes place on the specified day of every week, at the specified time </p></li>
49 <li class="listitem"><p>rotation takes place on the specified day of every month, at the specified time</p></li>
50 </ul></div>
51 <p>
52 The time points are considered to be local time. </p>
53 <div class="refsect2">
54 <a name="idp127370944"></a><h3>
55 <a name="boost.log.sinks.file.rotation_at_time_pointconstruct-copy-destruct"></a><code class="computeroutput">rotation_at_time_point</code> 
56         public
57        construct/copy/destruct</h3>
58 <div class="orderedlist"><ol class="orderedlist" type="1">
59 <li class="listitem">
60 <pre class="literallayout"><span class="keyword">explicit</span> <a name="idp65095456-bb"></a><span class="identifier">rotation_at_time_point</span><span class="special">(</span><span class="keyword">unsigned</span> <span class="keyword">char</span> hour<span class="special">,</span> <span class="keyword">unsigned</span> <span class="keyword">char</span> minute<span class="special">,</span> 
61                                 <span class="keyword">unsigned</span> <span class="keyword">char</span> second<span class="special">)</span><span class="special">;</span></pre>
62 <p>Creates a rotation time point of every day at the specified time</p>
63 <p>
64 </p>
65 <div class="variablelist"><table border="0" class="variablelist compact">
66 <colgroup>
67 <col align="left" valign="top">
68 <col>
69 </colgroup>
70 <tbody><tr>
71 <td><p><span class="term">Parameters:</span></p></td>
72 <td><div class="variablelist"><table border="0" class="variablelist compact">
73 <colgroup>
74 <col align="left" valign="top">
75 <col>
76 </colgroup>
77 <tbody>
78 <tr>
79 <td><p><span class="term"><code class="computeroutput">hour</code></span></p></td>
80 <td><p>The rotation hour, should be within 0 and 23 </p></td>
81 </tr>
82 <tr>
83 <td><p><span class="term"><code class="computeroutput">minute</code></span></p></td>
84 <td><p>The rotation minute, should be within 0 and 59 </p></td>
85 </tr>
86 <tr>
87 <td><p><span class="term"><code class="computeroutput">second</code></span></p></td>
88 <td><p>The rotation second, should be within 0 and 59 </p></td>
89 </tr>
90 </tbody>
91 </table></div></td>
92 </tr></tbody>
93 </table></div>
94 </li>
95 <li class="listitem">
96 <pre class="literallayout"><span class="keyword">explicit</span> <a name="idp65100176-bb"></a><span class="identifier">rotation_at_time_point</span><span class="special">(</span><span class="identifier">date_time</span><span class="special">::</span><span class="identifier">weekdays</span> wday<span class="special">,</span> 
97                                 <span class="keyword">unsigned</span> <span class="keyword">char</span> hour <span class="special">=</span> <span class="number">0</span><span class="special">,</span> 
98                                 <span class="keyword">unsigned</span> <span class="keyword">char</span> minute <span class="special">=</span> <span class="number">0</span><span class="special">,</span> 
99                                 <span class="keyword">unsigned</span> <span class="keyword">char</span> second <span class="special">=</span> <span class="number">0</span><span class="special">)</span><span class="special">;</span></pre>
100 <p>Creates a rotation time point of each specified weekday at the specified time</p>
101 <p>
102 </p>
103 <div class="variablelist"><table border="0" class="variablelist compact">
104 <colgroup>
105 <col align="left" valign="top">
106 <col>
107 </colgroup>
108 <tbody><tr>
109 <td><p><span class="term">Parameters:</span></p></td>
110 <td><div class="variablelist"><table border="0" class="variablelist compact">
111 <colgroup>
112 <col align="left" valign="top">
113 <col>
114 </colgroup>
115 <tbody>
116 <tr>
117 <td><p><span class="term"><code class="computeroutput">hour</code></span></p></td>
118 <td><p>The rotation hour, should be within 0 and 23 </p></td>
119 </tr>
120 <tr>
121 <td><p><span class="term"><code class="computeroutput">minute</code></span></p></td>
122 <td><p>The rotation minute, should be within 0 and 59 </p></td>
123 </tr>
124 <tr>
125 <td><p><span class="term"><code class="computeroutput">second</code></span></p></td>
126 <td><p>The rotation second, should be within 0 and 59 </p></td>
127 </tr>
128 <tr>
129 <td><p><span class="term"><code class="computeroutput">wday</code></span></p></td>
130 <td><p>The weekday of the rotation </p></td>
131 </tr>
132 </tbody>
133 </table></div></td>
134 </tr></tbody>
135 </table></div>
136 </li>
137 <li class="listitem">
138 <pre class="literallayout"><span class="keyword">explicit</span> <a name="idp65106896-bb"></a><span class="identifier">rotation_at_time_point</span><span class="special">(</span><span class="identifier">gregorian</span><span class="special">::</span><span class="identifier">greg_day</span> mday<span class="special">,</span> 
139                                 <span class="keyword">unsigned</span> <span class="keyword">char</span> hour <span class="special">=</span> <span class="number">0</span><span class="special">,</span> 
140                                 <span class="keyword">unsigned</span> <span class="keyword">char</span> minute <span class="special">=</span> <span class="number">0</span><span class="special">,</span> 
141                                 <span class="keyword">unsigned</span> <span class="keyword">char</span> second <span class="special">=</span> <span class="number">0</span><span class="special">)</span><span class="special">;</span></pre>
142 <p>Creates a rotation time point of each specified day of month at the specified time</p>
143 <p>
144 </p>
145 <div class="variablelist"><table border="0" class="variablelist compact">
146 <colgroup>
147 <col align="left" valign="top">
148 <col>
149 </colgroup>
150 <tbody><tr>
151 <td><p><span class="term">Parameters:</span></p></td>
152 <td><div class="variablelist"><table border="0" class="variablelist compact">
153 <colgroup>
154 <col align="left" valign="top">
155 <col>
156 </colgroup>
157 <tbody>
158 <tr>
159 <td><p><span class="term"><code class="computeroutput">hour</code></span></p></td>
160 <td><p>The rotation hour, should be within 0 and 23 </p></td>
161 </tr>
162 <tr>
163 <td><p><span class="term"><code class="computeroutput">mday</code></span></p></td>
164 <td><p>The monthday of the rotation, should be within 1 and 31 </p></td>
165 </tr>
166 <tr>
167 <td><p><span class="term"><code class="computeroutput">minute</code></span></p></td>
168 <td><p>The rotation minute, should be within 0 and 59 </p></td>
169 </tr>
170 <tr>
171 <td><p><span class="term"><code class="computeroutput">second</code></span></p></td>
172 <td><p>The rotation second, should be within 0 and 59 </p></td>
173 </tr>
174 </tbody>
175 </table></div></td>
176 </tr></tbody>
177 </table></div>
178 </li>
179 </ol></div>
180 </div>
181 <div class="refsect2">
182 <a name="idp127435664"></a><h3>
183 <a name="idp65093184-bb"></a><code class="computeroutput">rotation_at_time_point</code> public member functions</h3>
184 <div class="orderedlist"><ol class="orderedlist" type="1"><li class="listitem">
185 <pre class="literallayout"><span class="keyword">bool</span> <a name="idp65093744-bb"></a><span class="keyword">operator</span><span class="special">(</span><span class="special">)</span><span class="special">(</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span></pre>
186 <p>Checks if it's time to rotate the file </p>
187 </li></ol></div>
188 </div>
189 </div>
190 </div>
191 <table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
192 <td align="left"></td>
193 <td align="right"><div class="copyright-footer">Copyright &#169; 2007-2016 Andrey Semashev<p>
194         Distributed under the Boost Software License, Version 1.0. (See accompanying
195         file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>).
196       </p>
197 </div></td>
198 </tr></table>
199 <hr>
200 <div class="spirit-nav">
201 <a accesskey="p" href="collector.html"><img src="../../../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../../../../sinks.html#header.boost.log.sinks.text_file_backend_hpp"><img src="../../../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="rotation_at_time_interval.html"><img src="../../../../../../../../doc/src/images/next.png" alt="Next"></a>
202 </div>
203 </body>
204 </html>