Debian Codegraph @

core/docs/source/usage/library.rst

raw
1 Library
2 =======
3
4 Documentation for the open API of the library can be found in the :ref:`api:API` section.
5
6
7 Entry Points
8 ------------
9
10 This library has two main entry points you can use:
11
12 :py:class:`rstcheck_core.runner.RstcheckMainRunner` class
13 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
14
15 The ``RstcheckMainRunner`` class the is main entry point. It manages the configuration state,
16 runs the check on the files, caches the found linting issues and prints them.
17
18
19 :py:func:`rstcheck_core.checker.check_file` function
20 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
21
22 The ``check_file`` function is a step deeper. It checks a single file and returns a list of
23 the found linting issues. This would be the entry point if you don't need the additional
24 management capabilities of the ``RstcheckMainRunner`` class.
25
26
27 Logging
28 -------
29
30 ``rstcheck-core`` uses the standard library's ``logging`` module for its logging functionality.
31
32 Each python module has its own logger named after the ``__file__`` variable's value.
33
34 Following the `Official HOWTO`_ logging is deactivated by default, but can be activated,
35 if you as a developer provide a logging configuration.
36
37
38 .. _Official HOWTO: https://docs.python.org/3/howto/logging.html#configuring-logging-for-a-library