Kaydet (Commit) 25264d4e authored tarafından Tim Graham's avatar Tim Graham

Documented django.utils.timezone.FixedOffset; thanks Aymeric.

üst f6463bb3
...@@ -127,7 +127,7 @@ The functions defined in this module share the following properties: ...@@ -127,7 +127,7 @@ The functions defined in this module share the following properties:
Parses a string and returns a :class:`datetime.datetime`. Parses a string and returns a :class:`datetime.datetime`.
UTC offsets are supported; if ``value`` describes one, the result's UTC offsets are supported; if ``value`` describes one, the result's
``tzinfo`` attribute is a :class:`~django.utils.tzinfo.FixedOffset` ``tzinfo`` attribute is a :class:`~django.utils.timezone.FixedOffset`
instance. instance.
.. function:: parse_duration(value) .. function:: parse_duration(value)
...@@ -856,6 +856,13 @@ appropriate entities. ...@@ -856,6 +856,13 @@ appropriate entities.
:class:`~datetime.tzinfo` instance that represents UTC. :class:`~datetime.tzinfo` instance that represents UTC.
.. class:: FixedOffset(offset=None, name=None)
.. versionadded:: 1.7
A :class:`~datetime.tzinfo` subclass modeling a fixed offset from UTC.
``offset`` is an integer number of minutes east of UTC.
.. function:: get_fixed_timezone(offset) .. function:: get_fixed_timezone(offset)
.. versionadded:: 1.7 .. versionadded:: 1.7
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment