.. _f-blogpost: module ``sphinxext.blog_post`` ============================== .. inheritance-diagram:: pyquickhelper.sphinxext.blog_post Short summary +++++++++++++ module ``pyquickhelper.sphinxext.blog_post`` Helpers to process blog post included in the documentation. :githublink:`%|py|6` Classes +++++++ +------------------------------------------------------------------------------------+------------------------------------------------------------------+ | class | truncated documentation | +====================================================================================+==================================================================+ | :class:`BlogPost ` | Defines a blog post. | +------------------------------------------------------------------------------------+------------------------------------------------------------------+ | :class:`BlogPostParseError ` | Exception raised when a error comes after a blogpost was parsed. | +------------------------------------------------------------------------------------+------------------------------------------------------------------+ Properties ++++++++++ +------------------------------------------------------------------------------------+----------------------------------------------------------------------------+ | property | truncated documentation | +====================================================================================+============================================================================+ | :meth:`Author ` | Returns the author or None if not defined. | +------------------------------------------------------------------------------------+----------------------------------------------------------------------------+ | :meth:`BlogBackground ` | Returns the blog background or None if not defined. | +------------------------------------------------------------------------------------+----------------------------------------------------------------------------+ | :meth:`Categories ` | Returns the categories. | +------------------------------------------------------------------------------------+----------------------------------------------------------------------------+ | :meth:`Content ` | Returns the content of the blogpost. | +------------------------------------------------------------------------------------+----------------------------------------------------------------------------+ | :meth:`Date ` | Returns the date. | +------------------------------------------------------------------------------------+----------------------------------------------------------------------------+ | :meth:`Fields ` | Returns the fields as a dictionary. | +------------------------------------------------------------------------------------+----------------------------------------------------------------------------+ | :meth:`FileName ` | Returns the filename. | +------------------------------------------------------------------------------------+----------------------------------------------------------------------------+ | :meth:`Keywords ` | Returns the keywords. | +------------------------------------------------------------------------------------+----------------------------------------------------------------------------+ | :meth:`Tag ` | Produces a tag for the blog post. | +------------------------------------------------------------------------------------+----------------------------------------------------------------------------+ | :meth:`Title ` | Returns the title. | +------------------------------------------------------------------------------------+----------------------------------------------------------------------------+ | :meth:`Year ` | Returns the year, we assume ``self.date`` is a string like ``YYYY-MM-DD``. | +------------------------------------------------------------------------------------+----------------------------------------------------------------------------+ Static Methods ++++++++++++++ +--------------------------------------------------------------------------+----------------------------+ | staticmethod | truncated documentation | +==========================================================================+============================+ | :meth:`build_tag ` | Builds the tag for a post. | +--------------------------------------------------------------------------+----------------------------+ Methods +++++++ +-----------------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------+ | method | truncated documentation | +===================================================================================+==========================================================================================================+ | :py:meth:`__cmp__ ` | This method avoids to get the following error ``TypeError: unorderable types: BlogPost() < BlogPost()``. | +-----------------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------+ | :py:meth:`__init__ ` | Creates an instance of a blog post from a file or a string. | +-----------------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------+ | :py:meth:`__lt__ ` | Tells if this blog should be placed before *other*. | +-----------------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------+ | :py:meth:`_update_link ` | Changes a link to an image if the page contains one into *year/img.png*. | +-----------------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------+ | :meth:`post_as_rst ` | Reproduces the text of the blog post, updates the image links. | +-----------------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------+ Documentation +++++++++++++ .. automodule:: pyquickhelper.sphinxext.blog_post :members: :special-members: __init__ :show-inheritance: