/usr/share/doc/python-simpleparse-doc/doc/pydoc/simpleparse.common.iso_date.html is in python-simpleparse-doc 2.1.0a1-6.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 | <!doctype html PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html><head><title>Python: module simpleparse.common.iso_date</title>
</head><body bgcolor="#f0f0f8">
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="heading">
<tr bgcolor="#7799ee">
<td valign=bottom> <br>
<font color="#ffffff" face="helvetica, arial"> <br><big><big><strong><a href="simpleparse.html"><font color="#ffffff">simpleparse</font></a>.<a href="simpleparse.common.html"><font color="#ffffff">common</font></a>.iso_date</strong></big></big></font></td
><td align=right valign=bottom
><font color="#ffffff" face="helvetica, arial"><a href=".">index</a><br><a href="file:/home/mcfletch/pylive/simpleparse/common/iso_date.py">/home/mcfletch/pylive/simpleparse/common/iso_date.py</a></font></td></tr></table>
<p><tt>Canonical ISO date format YYYY-MM-DDTHH:mm:SS+HH:mm<br>
<br>
This parser is _extremely_ strict, and the dates that match it,<br>
though really easy to work with for the computer, are not particularly<br>
readable. See the iso_date_loose module for a slightly relaxed<br>
definition which allows the "T" character to be replaced by a<br>
" " character, and allows a space before the timezone offset, as well<br>
as allowing the integer values to use non-0-padded integers.<br>
<br>
<br>
ISO_date -- YYYY-MM-DD format, with a month and date optional<br>
ISO_time -- HH:mm:SS format, with minutes and seconds optional<br>
ISO_date_time -- YYYY-MM-DD HH:mm:SS+HH:mm format,<br>
with time optional and TimeZone offset optional<br>
<br>
Interpreter:<br>
<a href="#MxInterpreter">MxInterpreter</a><br>
Interprets the parse tree as mx.DateTime values<br>
ISO_date and ISO_time<br>
returns DateTime objects<br>
Time only<br>
returns RelativeDateTime object which, when<br>
added to a DateTime gives you the given time<br>
within that day</tt></p>
<p>
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
<tr bgcolor="#aa55cc">
<td colspan=3 valign=bottom> <br>
<font color="#fffff" face="helvetica, arial"><big><strong>Modules</strong></big></font></td></tr>
<tr><td bgcolor="#aa55cc"><tt> </tt></td><td> </td>
<td width="100%"><table width="100%" summary="list"><tr><td width="25%" valign=top><a href="mx.DateTime.html">mx.DateTime</a><br>
<a href="simpleparse.common.chartypes.html">simpleparse.common.chartypes</a><br>
</td><td width="25%" valign=top><a href="simpleparse.common.html">simpleparse.common</a><br>
<a href="simpleparse.common.numbers.html">simpleparse.common.numbers</a><br>
</td><td width="25%" valign=top><a href="simpleparse.objectgenerator.html">simpleparse.objectgenerator</a><br>
</td><td width="25%" valign=top></td></tr></table></td></tr></table><p>
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
<tr bgcolor="#ee77aa">
<td colspan=3 valign=bottom> <br>
<font color="#ffffff" face="helvetica, arial"><big><strong>Classes</strong></big></font></td></tr>
<tr><td bgcolor="#ee77aa"><tt> </tt></td><td> </td>
<td width="100%"><dl>
<dt><font face="helvetica, arial"><a href="simpleparse.dispatchprocessor.html#DispatchProcessor">DispatchProcessor</a>(<a href="simpleparse.processor.html#Processor">Processor</a>)
</font></dt><dd>
<dl>
<dt><font face="helvetica, arial"><a href="simpleparse.common.iso_date.html#MxInterpreter">MxInterpreter</a>
</font></dt></dl>
</dd>
</dl>
<p>
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
<tr bgcolor="#ffc8d8">
<td colspan=3 valign=bottom> <br>
<font color="#000000" face="helvetica, arial"><a name="MxInterpreter">class <strong>MxInterpreter</strong></a>(<a href="simpleparse.dispatchprocessor.html#DispatchProcessor">DispatchProcessor</a>)</font></td></tr>
<tr bgcolor="#ffc8d8"><td rowspan=2><tt> </tt></td>
<td colspan=2><tt>Interpret a parsed ISO_date_time_loose in GMT/UTC time or localtime<br> </tt></td></tr>
<tr><td> </td>
<td width="100%"><dl><dt>Method resolution order:</dt>
<dd><a href="simpleparse.common.iso_date.html#MxInterpreter">MxInterpreter</a></dd>
<dd><a href="simpleparse.dispatchprocessor.html#DispatchProcessor">DispatchProcessor</a></dd>
<dd><a href="simpleparse.processor.html#Processor">Processor</a></dd>
<dd><a href="simpleparse.processor.html#MethodSource">MethodSource</a></dd>
</dl>
<hr>
Methods defined here:<br>
<dl><dt><a name="MxInterpreter-ISO_date"><strong>ISO_date</strong></a>(self, (tag, left, right, sublist), buffer)</dt><dd><tt>Interpret the ISO date format</tt></dd></dl>
<dl><dt><a name="MxInterpreter-ISO_date_time"><strong>ISO_date_time</strong></a>(self, (tag, left, right, sublist), buffer)</dt><dd><tt>Interpret the loose ISO date + time format</tt></dd></dl>
<dl><dt><a name="MxInterpreter-ISO_time"><strong>ISO_time</strong></a>(self, (tag, left, right, sublist), buffer)</dt><dd><tt>Interpret the ISO time format</tt></dd></dl>
<dl><dt><a name="MxInterpreter-__init__"><strong>__init__</strong></a>(self, inputLocal<font color="#909090">=1</font>, returnLocal<font color="#909090">=1</font>)</dt></dl>
<dl><dt><a name="MxInterpreter-offset"><strong>offset</strong></a>(self, (tag, left, right, sublist), buffer)</dt><dd><tt>Calculate the time zone offset as a date-time delta</tt></dd></dl>
<dl><dt><a name="MxInterpreter-offset_sign"><strong>offset_sign</strong></a>(self, (tag, left, right, sublist), buffer)</dt><dd><tt>Interpret the offset sign as a multiplier</tt></dd></dl>
<hr>
Data and other attributes defined here:<br>
<dl><dt><strong>dateName</strong> = 'ISO_date'</dl>
<dl><dt><strong>day</strong> = <IntInterpreter object @ 46912541558904><dd><tt>Interpret an integer (or unsigned integer) string as an integer</tt></dl>
<dl><dt><strong>hour</strong> = <IntInterpreter object @ 46912541558904><dd><tt>Interpret an integer (or unsigned integer) string as an integer</tt></dl>
<dl><dt><strong>integer</strong> = <IntInterpreter object @ 46912541558904><dd><tt>Interpret an integer (or unsigned integer) string as an integer</tt></dl>
<dl><dt><strong>minute</strong> = <IntInterpreter object @ 46912541558904><dd><tt>Interpret an integer (or unsigned integer) string as an integer</tt></dl>
<dl><dt><strong>month</strong> = <IntInterpreter object @ 46912541558904><dd><tt>Interpret an integer (or unsigned integer) string as an integer</tt></dl>
<dl><dt><strong>offset_hour</strong> = <IntInterpreter object @ 46912541558904><dd><tt>Interpret an integer (or unsigned integer) string as an integer</tt></dl>
<dl><dt><strong>offset_minute</strong> = <IntInterpreter object @ 46912541558904><dd><tt>Interpret an integer (or unsigned integer) string as an integer</tt></dl>
<dl><dt><strong>second</strong> = <IntInterpreter object @ 46912541558904><dd><tt>Interpret an integer (or unsigned integer) string as an integer</tt></dl>
<dl><dt><strong>timeName</strong> = 'ISO_time'</dl>
<dl><dt><strong>year</strong> = <IntInterpreter object @ 46912541558904><dd><tt>Interpret an integer (or unsigned integer) string as an integer</tt></dl>
<hr>
Methods inherited from <a href="simpleparse.dispatchprocessor.html#DispatchProcessor">DispatchProcessor</a>:<br>
<dl><dt><a name="MxInterpreter-__call__"><strong>__call__</strong></a>(self, value, buffer)</dt><dd><tt>Process the results of the parsing run over buffer<br>
<br>
Value can either be: (success, tags, next) for a top-level<br>
production, or (tag, left, right, children) for a non-top<br>
production.</tt></dd></dl>
<hr>
Methods inherited from <a href="simpleparse.processor.html#Processor">Processor</a>:<br>
<dl><dt><a name="MxInterpreter-__repr__"><strong>__repr__</strong></a>(self)</dt><dd><tt>Return a representation of the class</tt></dd></dl>
</td></tr></table></td></tr></table><p>
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
<tr bgcolor="#55aa55">
<td colspan=3 valign=bottom> <br>
<font color="#ffffff" face="helvetica, arial"><big><strong>Data</strong></big></font></td></tr>
<tr><td bgcolor="#55aa55"><tt> </tt></td><td> </td>
<td width="100%"><strong>_p</strong> = <simpleparse.parser.Parser instance><br>
<strong>c</strong> = {'ISO_date': LibraryElement(
production = 'ISO_date',
...enerator.Generator instance at 0x2aaaad5dca28>,
), 'ISO_date_time': LibraryElement(
production = 'ISO_date_time'...enerator.Generator instance at 0x2aaaad5dca28>,
), 'ISO_time': LibraryElement(
production = 'ISO_time',
...enerator.Generator instance at 0x2aaaad5dca28>,
)}<br>
<strong>declaration</strong> = '<font color="#c040c0">\n</font>year := digit,digit,digit,digit<font color="#c040c0">\n</font>month ...ate_time := ISO_date, ([T], ISO_time)?, offset?<font color="#c040c0">\n</font>'<br>
<strong>haveMX</strong> = 1<br>
<strong>name</strong> = 'ISO_date_time'</td></tr></table>
</body></html>
|