2021.4.post1 #31

Merged
edraft merged 92 commits from 2021.4.post1 into master 2021-05-19 09:00:40 +02:00
314 changed files with 37667 additions and 817 deletions
Showing only changes of commit 69f697e36f - Show all commits

20
docs/Makefile Normal file
View File

@ -0,0 +1,20 @@
# Minimal makefile for Sphinx documentation
#
# You can set these variables from the command line, and also
# from the environment for the first two.
SPHINXOPTS ?=
SPHINXBUILD ?= sphinx-build
SOURCEDIR = source
BUILDDIR = build
# Put it first so that "make" without argument is like "make help".
help:
@$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
.PHONY: help Makefile
# Catch-all target: route all unknown targets to Sphinx using the new
# "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS).
%: Makefile
@$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)

BIN
docs/build/doctrees/cli.add.doctree vendored Normal file

Binary file not shown.

BIN
docs/build/doctrees/cli.build.doctree vendored Normal file

Binary file not shown.

BIN
docs/build/doctrees/cli.generate.doctree vendored Normal file

Binary file not shown.

BIN
docs/build/doctrees/cli.help.doctree vendored Normal file

Binary file not shown.

BIN
docs/build/doctrees/cli.install.doctree vendored Normal file

Binary file not shown.

BIN
docs/build/doctrees/cli.new.doctree vendored Normal file

Binary file not shown.

BIN
docs/build/doctrees/cli.overview.doctree vendored Normal file

Binary file not shown.

BIN
docs/build/doctrees/cli.publish.doctree vendored Normal file

Binary file not shown.

BIN
docs/build/doctrees/cli.remove.doctree vendored Normal file

Binary file not shown.

BIN
docs/build/doctrees/cli.start.doctree vendored Normal file

Binary file not shown.

Binary file not shown.

BIN
docs/build/doctrees/cli.update.doctree vendored Normal file

Binary file not shown.

BIN
docs/build/doctrees/cli.version.doctree vendored Normal file

Binary file not shown.

BIN
docs/build/doctrees/contributing.doctree vendored Normal file

Binary file not shown.

Binary file not shown.

Binary file not shown.

BIN
docs/build/doctrees/cpl.console.doctree vendored Normal file

Binary file not shown.

Binary file not shown.

Binary file not shown.

BIN
docs/build/doctrees/cpl.database.doctree vendored Normal file

Binary file not shown.

Binary file not shown.

BIN
docs/build/doctrees/cpl.doctree vendored Normal file

Binary file not shown.

Binary file not shown.

BIN
docs/build/doctrees/cpl.logging.doctree vendored Normal file

Binary file not shown.

BIN
docs/build/doctrees/cpl.mailing.doctree vendored Normal file

Binary file not shown.

BIN
docs/build/doctrees/cpl.time.doctree vendored Normal file

Binary file not shown.

BIN
docs/build/doctrees/cpl.utils.doctree vendored Normal file

Binary file not shown.

BIN
docs/build/doctrees/cpl_cli.doctree vendored Normal file

Binary file not shown.

BIN
docs/build/doctrees/environment.pickle vendored Normal file

Binary file not shown.

Binary file not shown.

BIN
docs/build/doctrees/index.doctree vendored Normal file

Binary file not shown.

BIN
docs/build/doctrees/introduction.doctree vendored Normal file

Binary file not shown.

BIN
docs/build/doctrees/modules.doctree vendored Normal file

Binary file not shown.

BIN
docs/build/doctrees/quickstart.doctree vendored Normal file

Binary file not shown.

BIN
docs/build/doctrees/setup.doctree vendored Normal file

Binary file not shown.

4
docs/build/html/.buildinfo vendored Normal file
View File

@ -0,0 +1,4 @@
# Sphinx build info version 1
# This file hashes the configuration used when building these files. When it is not found, a full rebuild will be done.
config: 8170277cf12e5442e6180427108a8adf
tags: 645f666f9bcd5a90fca523b33c5a78b7

BIN
docs/build/html/_images/ide-emulate.png vendored Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 55 KiB

BIN
docs/build/html/_images/ide-src.png vendored Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 54 KiB

BIN
docs/build/html/_images/ide.png vendored Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 28 KiB

25
docs/build/html/_sources/cli.add.md.txt vendored Normal file
View File

@ -0,0 +1,25 @@
# cpl add
## Contents
- [Description](#description)
- [Arguments](#arguments)
Removes a project from workspace.
cpl **add** *&lt;source-project&gt;* *&lt;target-project&gt;* <br>
cpl **a** *&lt;source-project&gt;* *&lt;target-project&gt;* <br>
cpl **A** *&lt;source-project&gt;* *&lt;target-project&gt;*
## Description
Adds a project reference to given project.
If you call the command in a CPL workspace, you can use the project names. Otherwise the paths of the projects must be specified.
## Arguments
| Argument | Description | Value type |
| ------------------------- |:---------------------------------------------------------------:|:----------------:|
| ```<source-project>``` | Name of the project to which the reference has to be added | ```str```
| ```<target-project>``` | Name of the project to be referenced | ```str```

View File

@ -0,0 +1,26 @@
# cpl build
## Contents
- [Description](#description)
<!-- - [Arguments](#arguments) -->
Copies an python app into an output directory named build/ at the given output path. Must be executed within a CPL workspace or project directory
cpl **build** <br>
cpl **b** <br>
cpl **B**
## Description
The command can be used to build a project of type "console" or "library".
The build command copies all included source files to the output directory. You can run the source files in the output directory directly.
The command is used to prepare the source files for the publish command or to copy them to an target for execution.
<!-- ## Arguments
| Argument | Description | Value type |
| ------------- |:-------------:|:----------------:|
| ```<project>``` | The name of the project to build. Can be an console or a library. | ```str``` -->

View File

@ -0,0 +1,35 @@
# cpl generate
## Contents
- [Description](#description)
- [Arguments](#arguments)
- [Schematics](#schematics)
Generate a file based on schematic.
cpl **generate** *&lt;schematic&gt;* *&lt;name&gt;* <br>
cpl **g** *&lt;schematic&gt;* *&lt;name&gt;* <br>
cpl **G** *&lt;schematic&gt;* *&lt;name&gt;*
## Description
Generates files based on a schematic.
## Arguments
| Argument | Description | Value type |
| ----------------- |:---------------------------------:|:-------------:|
| ```<schematic>``` | The schematic to generate. | ```str``` |
| ```<name>``` | The name of the generated file. | ```str``` |
## Schematics
| Schematic | Description | Arguments |
| ----------------- |:-------------------:|:----------------:|
| ```abc``` | Abstract base class | ```<name>```
| ```class``` | Class | ```<name>```
| ```enum``` | Enum class | ```<name>```
| ```service``` | Service class | ```<name>```
| ```settings``` | [Configmodel](cpl.configuration) | ```<name>```
| ```thread``` | Thread class | ```<name>```

View File

@ -0,0 +1,22 @@
# cpl help
<!-- ## Contents
- [Description](#description) -->
<!-- - [Arguments](#arguments) -->
Lists available command and their short descriptions.
cpl **help** *&lt;command&gt;* <br>
cpl **h** *&lt;command&gt;* <br>
cpl **H** *&lt;command&gt;*
## Description
Lists available command and their short descriptions.
## Arguments
| Argument | Description | Value type |
| ----------------- |:-----------------------------:|:-------------:|
| ```<command>``` | Shows a help message for this command in the console. | ```str``` |

View File

@ -0,0 +1,23 @@
# cpl install
## Contents
- [Description](#description)
- [Arguments](#arguments)
Installs given package via pip
cpl **install** *&lt;package&gt;* <br>
cpl **i** *&lt;package&gt;* <br>
cpl **I** *&lt;package&gt;*
## Description
Install given package to project via pip.
Without given package it will install the depedencies of the CPL project your in.
## Arguments
| Argument | Description | Value type |
| ----------------- |:-----------------------------:|:-------------:|
| ```<package>``` | The package to install | ```str``` |

31
docs/build/html/_sources/cli.new.md.txt vendored Normal file
View File

@ -0,0 +1,31 @@
# cpl new
## Contents
- [Description](#description)
- [Arguments](#arguments)
- [Project types](#project-types)
Generates a workspace and initial project or add a project to workspace.
cpl **new** *&lt;type&gt;* *&lt;name&gt;*<br>
cpl **n** *&lt;type&gt;* *&lt;name&gt;* <br>
cpl **N** *&lt;type&gt;* *&lt;name&gt;*
## Description
Generates a workspace and initial project or add a project to workspace.
If the command is running in a CPL workspace, it will add the new project to the workspace.
| Argument | Description | Value type |
| ----------------- |:-----------------------------------------------------:|:-------------:|
| ```<type>``` | The type of the project, see [types](#project-types) | ```str``` |
| ```<name>``` | The name of the project | ```str``` |
## Project types
| Project type | Description |
| ----------------- |:-----------------------------:|
| ```console``` | A simple console application |
| ```library``` | A package |

View File

@ -0,0 +1,53 @@
# CLI Overview and Command Reference
## Table of Contents
1. [Install CPL](setup#install-the-package)
2. [Install CPL CLI](setup#install-the-cli)
3. [Basic workflow](#basic-workflow)
4. [CLI command-language syntax](#cli-command-language-syntax)
5. [Command overview](#command-overview)
## Basic workflow
To create, build, and serve a new, basic CPL project on a development server, go to the parent directory of your new workspace use the following commands:
```sh
cpl new console my-first-project
cd my-first-project
cpl start
```
In the terminal you will the output of the app.
## CLI command-language syntax
```cpl``` commandNameOrAlias requiredArg ```[optionalsArgs]```
- Most commands, and some options, have aliases. Aliases are shown in the syntax statement for each command.
- Arguments are not prefixed.
### Relative paths
Options that specify files can be given as absolute paths, or as paths relative to the current working directory, which is generally either the workspace or project root.
### Schematics
The cpl generate command takes as an argument the artifact to be generated. In addition to any general options, each artifact defines its own options in a schematic. Schematic options are supplied to the command in the same format as immediate command options.
## Command overview
| Command | Alias | Description |
| ----------------------------- |:-------------:|:----------------:|
| [add](cli.add) | a or a | Adds a project reference to given project.
| [build](cli.build) | b or B | Prepares files for publish into an output directory named dist/ at the given output path. Must be executed from within a workspace directory.
| [generate](cli.generate) | g or G | Generate a new file.
| [help](cli.help) | h or H | Lists available command and their short descriptions.
| [install](cli.install) | i or I | With argument installs packages to project, without argument installs project dependencies.
| [new](cli.new) | n or N | Creates new CPL project.
| [publish](cli.publish) | p or P | Prepares files for publish into an output directory named dist/ at the given output path and executes ```setup.py```. Must be executed from within a library workspace directory.
| [remove](cli.remove) | r or R | Removes a project from workspace.
| [start](cli.start) | s or S | Starts CPL project, restarting on file changes.
| [uninstall](cli.uninstall) | ui or UI | Uninstalls packages from project.
| [update](cli.update) | u or U | Update CPL and project dependencies.
| [version](cli.version) | v or V | Outputs CPL CLI version.

View File

@ -0,0 +1,27 @@
# cpl publish
## Contents
- [Description](#description)
<!-- - [Arguments](#arguments) -->
Prepares files for publish into an output directory named dist/ at the given output path and executes ```setup.py```.
cpl **publish** <br>
cpl **p** <br>
cpl **P**
## Description
The command can be used to publish a project of type "console" or "library".
The publish command builds the source files and then creates an ```setup.py``` with data from ```cpl.json```.
The command executes the ```setup.py``` and removes all source files with the ```setup.py``` from the 'publish/' directory.
Generated files of ```setup.py``` are in the 'publish/setup/' directory.
<!-- ## Arguments
| Argument | Description | Value type |
| ------------- |:-------------:|:----------------:|
| ```<project>``` | The name of the project to build. Can be an console or a library. | ```str``` -->

View File

@ -0,0 +1,27 @@
# cpl remove
## Contents
- [Description](#description)
- [Arguments](#arguments)
Removes a project from workspace.
cpl **remove** *&lt;project&gt;* <br>
cpl **r** *&lt;project&gt;* <br>
cpl **R** *&lt;project&gt;*
## Description
The command can be used to publish a project of type "console" or "library".
The publish command builds the source files and then creates an ```setup.py``` with data from ```cpl.json```.
The command executes the ```setup.py``` and removes all source files with the ```setup.py``` from the 'publish/' directory.
Generated files of ```setup.py``` are in the 'publish/setup/' directory.
## Arguments
| Argument | Description | Value type |
| ------------------------- |:-------------------------------------:|:----------------:|
| ```<project>``` | The name of the project to delete | ```str```

View File

@ -0,0 +1,7 @@
# cpl start
Starts your application, restarting on file changes.
cpl **start** <br>
cpl **s** <br>
cpl **S**

View File

@ -0,0 +1,22 @@
# cpl uninstall
## Contents
- [Description](#description)
- [Arguments](#arguments)
Uninstalls given package via pip
cpl **uninstall** *&lt;package&gt;* <br>
cpl **ui** *&lt;package&gt;* <br>
cpl **UI** *&lt;package&gt;*
## Description
Uninstall given package from project via pip.
## Arguments
| Argument | Description | Value type |
| ----------------- |:-----------------------------:|:-------------:|
| ```<package>``` | The package to uninstall | ```str``` |

View File

@ -0,0 +1,7 @@
# cpl update
Updates the CPL and project dependencies.
cpl **update** <br>
cpl **u** <br>
cpl **U**

View File

@ -0,0 +1,7 @@
# cpl version
Lists the version of CPL, CPL CLI and all installed packages from pip.
cpl **version** <br>
cpl **v** <br>
cpl **V**

View File

@ -0,0 +1,111 @@
# Contributing to CPL
We would love for you to contribute to CPL and help make it even better than it is today! As a contributor, here are the guidelines we would like you to follow:
- [Issuses and Bugs](#found-a-bug)
- [Feature Request](#feature-request)
- [Submission Guidelines](#submission-guidelines)
- [Coding Rules](#coding-rules)
- [License](#license)
## Found a Bug?
If you find a bug in the source code, you can help us by [submitting an issue](#submitting-an-issue) to our [Gitea Repository][gitea-repo]. Even better, you can [submit a Pull Request](#submitting-a-pull-request) with a fix.
## Feature Request
You can request a new feature by submitting an issue to our [Gitea Repository][gitea-repo]. If you would like to implement a new feature, please consider the size of the change in order to determine the right steps to proceed:
For a Major Feature, first open an issue and outline your proposal so that it can be discussed. This process allows us to better coordinate our efforts, prevent duplication of work, and help you to craft the change so that it is successfully accepted into the project.
Note: Adding a new topic to the documentation, or significantly re-writing a topic, counts as a major feature.
Small Features can be crafted and directly submitted as a [Pull Request](#submit-pr).
## Submission Guidelines
### Submitting an Issue
Before you submit an issue, please search the issue tracker, maybe an issue for your problem already exists and the discussion might inform you of workarounds readily available.
We want to fix all the issues as soon as possible, but before fixing a bug we need to reproduce and confirm it. In order to reproduce bugs, we require that you provide a minimal reproduction. Having a minimal reproducible scenario gives us a wealth of important information without going back and forth to you with additional questions.
A minimal reproduction allows us to quickly confirm a bug (or point out a coding problem) as well as confirm that we are fixing the right problem.
We require a minimal reproduction to save maintainers' time and ultimately be able to fix more bugs. Often, developers find coding problems themselves while preparing a minimal reproduction. We understand that sometimes it might be hard to extract essential bits of code from a larger codebase but we really need to isolate the problem before we can fix it.
Unfortunately, we are not able to investigate / fix bugs without a minimal reproduction, so if we don't hear back from you, we are going to close an issue that doesn't have enough info to be reproduced.
### Submitting a Pull Request
Before you submit your Pull Request (PR) consider the following guidelines:
1. Search the [repository][gitea-repo] for an open or closed PR that relates to your submission. You don't want to duplicate existing efforts.
2. Be sure that an issue describes the problem you're fixing, or documents the design for the feature you'd like to add. Discussing the design upfront helps to ensure that we're ready to accept your work.
3. Fork the sh-edraft.de/sh_cpl repo.
4. In your forked repository, make your changes in a new git branch:
```sh
git checkout -b my-fix-branch master
```
5. Create your patch, including appropriate test cases.
<!-- 6. Follow our [Coding Rules](coding-rules). -->
6. Commit your changes.
```sh
git commit --all
```
Note: the optional commit ```-a``` command line option will automatically "add" and "rm" edited files.
7. Push your branch to the [repository][gitea-repo]:
```sh
git push origin my-fix-branch
```
8. In Gitea, send a pull request to sh_cpl:master
### Reviewing a Pull Request
The sh-edraft.de team reserves the right not to accept pull requests from community members who haven't been good citizens of the community. Such behavior includes not following the CPL [coding rules](#coding-rules) and applies within or outside of CPL managed channels.
#### Addressing review feedback
If we ask for changes via code reviews then:
1. Make the required updates to the code.
2. Create a fixup commit and push to your repository (this will update your Pull Request):
```sh
git commit --all --fixup HEAD
git push
```
That's it! Thank you for your contribution!
## Coding Rules
To ensure consistency throughout the source code, keep these rules in mind as you are working:
- All features or bug fixes must be tested by one or more unit-tests.
- All public API methods must be documented.
- We follow [PEP 8 -- Style Guide for Python Code](https://www.python.org/dev/peps/pep-0008/).
## License
By contributing, you agree that your contributions will be licensed under its MIT License.
See [LICENSE](https://git.sh-edraft.de/sh-edraft.de/sh_cpl/src/branch/master/LICENSE)
<!-- LINKS -->
[gitea-repo]: https://git.sh-edraft.de/sh-edraft.de/sh_cpl/
[coding-rules]: /

View File

@ -0,0 +1,34 @@
cpl.application
=======================
cpl.application.application\_abc
---------------------------------------
.. automodule:: cpl.application.application_abc
:members:
:undoc-members:
:show-inheritance:
cpl.application.application\_builder
-------------------------------------------
.. automodule:: cpl.application.application_builder
:members:
:undoc-members:
:show-inheritance:
cpl.application.application\_builder\_abc
------------------------------------------------
.. automodule:: cpl.application.application_builder_abc
:members:
:undoc-members:
:show-inheritance:
cpl.application.startup\_abc
-----------------------------------
.. automodule:: cpl.application.startup_abc
:members:
:undoc-members:
:show-inheritance:

View File

@ -0,0 +1,42 @@
cpl.configuration
=========================
cpl.configuration.configuration
--------------------------------------
.. automodule:: cpl.configuration.configuration
:members:
:undoc-members:
:show-inheritance:
cpl.configuration.configuration\_abc
-------------------------------------------
.. automodule:: cpl.configuration.configuration_abc
:members:
:undoc-members:
:show-inheritance:
cpl.configuration.configuration\_model\_abc
--------------------------------------------------
.. automodule:: cpl.configuration.configuration_model_abc
:members:
:undoc-members:
:show-inheritance:
cpl.configuration.configuration\_variable\_name\_enum
------------------------------------------------------------
.. automodule:: cpl.configuration.configuration_variable_name_enum
:members:
:undoc-members:
:show-inheritance:
cpl.configuration.console\_argument
------------------------------------------
.. automodule:: cpl.configuration.console_argument
:members:
:undoc-members:
:show-inheritance:

View File

@ -0,0 +1,42 @@
cpl.console
===================
cpl.console.background\_color\_enum
------------------------------------------
.. automodule:: cpl.console.background_color_enum
:members:
:undoc-members:
:show-inheritance:
cpl.console.console
--------------------------
.. automodule:: cpl.console.console
:members:
:undoc-members:
:show-inheritance:
cpl.console.console\_call
--------------------------------
.. automodule:: cpl.console.console_call
:members:
:undoc-members:
:show-inheritance:
cpl.console.foreground\_color\_enum
------------------------------------------
.. automodule:: cpl.console.foreground_color_enum
:members:
:undoc-members:
:show-inheritance:
cpl.console.spinner\_thread
----------------------------------
.. automodule:: cpl.console.spinner_thread
:members:
:undoc-members:
:show-inheritance:

View File

@ -0,0 +1,18 @@
cpl.database.connection
===============================
cpl.database.connection.database\_connection
---------------------------------------------------
.. automodule:: cpl.database.connection.database_connection
:members:
:undoc-members:
:show-inheritance:
cpl.database.connection.database\_connection\_abc
--------------------------------------------------------
.. automodule:: cpl.database.connection.database_connection_abc
:members:
:undoc-members:
:show-inheritance:

View File

@ -0,0 +1,18 @@
cpl.database.context
============================
cpl.database.context.database\_context
---------------------------------------------
.. automodule:: cpl.database.context.database_context
:members:
:undoc-members:
:show-inheritance:
cpl.database.context.database\_context\_abc
--------------------------------------------------
.. automodule:: cpl.database.context.database_context_abc
:members:
:undoc-members:
:show-inheritance:

View File

@ -0,0 +1,35 @@
cpl.database
====================
.. toctree::
:maxdepth: 4
cpl.database.connection
cpl.database.context
Submodules
----------
cpl.database.database\_model
-----------------------------------
.. automodule:: cpl.database.database_model
:members:
:undoc-members:
:show-inheritance:
cpl.database.database\_settings
--------------------------------------
.. automodule:: cpl.database.database_settings
:members:
:undoc-members:
:show-inheritance:
cpl.database.database\_settings\_name\_enum
--------------------------------------------------
.. automodule:: cpl.database.database_settings_name_enum
:members:
:undoc-members:
:show-inheritance:

View File

@ -0,0 +1,50 @@
cpl.dependency\_injection
=================================
cpl.dependency\_injection.service\_collection
----------------------------------------------------
.. automodule:: cpl.dependency_injection.service_collection
:members:
:undoc-members:
:show-inheritance:
cpl.dependency\_injection.service\_collection\_abc
---------------------------------------------------------
.. automodule:: cpl.dependency_injection.service_collection_abc
:members:
:undoc-members:
:show-inheritance:
cpl.dependency\_injection.service\_descriptor
----------------------------------------------------
.. automodule:: cpl.dependency_injection.service_descriptor
:members:
:undoc-members:
:show-inheritance:
cpl.dependency\_injection.service\_lifetime\_enum
--------------------------------------------------------
.. automodule:: cpl.dependency_injection.service_lifetime_enum
:members:
:undoc-members:
:show-inheritance:
cpl.dependency\_injection.service\_provider
--------------------------------------------------
.. automodule:: cpl.dependency_injection.service_provider
:members:
:undoc-members:
:show-inheritance:
cpl.dependency\_injection.service\_provider\_abc
-------------------------------------------------------
.. automodule:: cpl.dependency_injection.service_provider_abc
:members:
:undoc-members:
:show-inheritance:

View File

@ -0,0 +1,26 @@
cpl.environment
=======================
cpl.environment.application\_environment
-----------------------------------------------
.. automodule:: cpl.environment.application_environment
:members:
:undoc-members:
:show-inheritance:
cpl.environment.application\_environment\_abc
----------------------------------------------------
.. automodule:: cpl.environment.application_environment_abc
:members:
:undoc-members:
:show-inheritance:
cpl.environment.environment\_name\_enum
----------------------------------------------
.. automodule:: cpl.environment.environment_name_enum
:members:
:undoc-members:
:show-inheritance:

View File

@ -0,0 +1,42 @@
cpl.logging
===================
cpl.logging.logger\_abc
------------------------------
.. automodule:: cpl.logging.logger_abc
:members:
:undoc-members:
:show-inheritance:
cpl.logging.logger\_service
----------------------------------
.. automodule:: cpl.logging.logger_service
:members:
:undoc-members:
:show-inheritance:
cpl.logging.logging\_level\_enum
---------------------------------------
.. automodule:: cpl.logging.logging_level_enum
:members:
:undoc-members:
:show-inheritance:
cpl.logging.logging\_settings
------------------------------------
.. automodule:: cpl.logging.logging_settings
:members:
:undoc-members:
:show-inheritance:
cpl.logging.logging\_settings\_name\_enum
------------------------------------------------
.. automodule:: cpl.logging.logging_settings_name_enum
:members:
:undoc-members:
:show-inheritance:

View File

@ -0,0 +1,42 @@
cpl.mailing
===================
cpl.mailing.email
------------------------
.. automodule:: cpl.mailing.email
:members:
:undoc-members:
:show-inheritance:
cpl.mailing.email\_client\_abc
-------------------------------------
.. automodule:: cpl.mailing.email_client_abc
:members:
:undoc-members:
:show-inheritance:
cpl.mailing.email\_client\_service
-----------------------------------------
.. automodule:: cpl.mailing.email_client_service
:members:
:undoc-members:
:show-inheritance:
cpl.mailing.email\_client\_settings
------------------------------------------
.. automodule:: cpl.mailing.email_client_settings
:members:
:undoc-members:
:show-inheritance:
cpl.mailing.email\_client\_settings\_name\_enum
------------------------------------------------------
.. automodule:: cpl.mailing.email_client_settings_name_enum
:members:
:undoc-members:
:show-inheritance:

16
docs/build/html/_sources/cpl.rst.txt vendored Normal file
View File

@ -0,0 +1,16 @@
API Reference
===========
.. toctree::
:maxdepth: 4
cpl.application
cpl.configuration
cpl.console
cpl.database
cpl.dependency_injection
cpl.environment
cpl.logging
cpl.mailing
cpl.time
cpl.utils

View File

@ -0,0 +1,18 @@
cpl.time
================
cpl.time.time\_format\_settings
--------------------------------------
.. automodule:: cpl.time.time_format_settings
:members:
:undoc-members:
:show-inheritance:
cpl.time.time\_format\_settings\_names\_enum
---------------------------------------------------
.. automodule:: cpl.time.time_format_settings_names_enum
:members:
:undoc-members:
:show-inheritance:

View File

@ -0,0 +1,26 @@
cpl.utils
=================
cpl.utils.credential\_manager
------------------------------------
.. automodule:: cpl.utils.credential_manager
:members:
:undoc-members:
:show-inheritance:
cpl.utils.pip
--------------------
.. automodule:: cpl.utils.pip
:members:
:undoc-members:
:show-inheritance:
cpl.utils.string
-----------------------
.. automodule:: cpl.utils.string
:members:
:undoc-members:
:show-inheritance:

View File

@ -0,0 +1,19 @@
CLI Reference
=============
.. toctree::
:maxdepth: 4
cli.overview
cli.add
cli.build
cli.generate
cli.help
cli.install
cli.new
cli.publish
cli.remove
cli.start
cli.uninstall
cli.update
cli.version

View File

@ -0,0 +1,9 @@
Getting started
===============
.. toctree::
:maxdepth: 4
quickstart
setup

24
docs/build/html/_sources/index.rst.txt vendored Normal file
View File

@ -0,0 +1,24 @@
.. Common Python Library documentation master file, created by
sphinx-quickstart on Wed Apr 14 10:25:36 2021.
You can adapt this file completely to your liking, but it should at least
contain the root `toctree` directive.
Introduction to the CPL Docs
============================
The Common Python Library (CPL) is a package for python and a development platform meant to help you create simple and efficient server and desktop applications.
This CPL docs help you learn, understand and use the package. From your first application to complex apps for enterprises.
Manuals
---------
These pages go into great detail about everything the Library can do.
.. toctree::
:maxdepth: 1
introduction
getting_started
cpl
cpl_cli

View File

@ -0,0 +1,12 @@
# Introduction to the CPL Docs
The Common Python Library (CPL) is a package for python and a development platform meant to help you create simple and efficient server and desktop applications.
This CPL docs help you learn, understand and use the package. From your first application to complex apps for enterprises.
## Explore
- [Getting started](quickstart)
- [Setup](setup)
- [API Reference](cpl)
- [CLI Reference](cli.overview)

View File

@ -0,0 +1,9 @@
cpl
===
.. toctree::
:maxdepth: 4
getting_started
cpl
cpl_cli

View File

@ -0,0 +1,210 @@
# Getting started with CPL
Welcome to CPL!
This tutorial introduces you to the essentials of the CPL package by walking through building an console based app.
## Table of Contents
1. [Prerequisites](#prerequisites)
2. [Create the project](#create-the-project)
3. [Create a menu](#create-a-menu)
4. [What's next](#whats-next)
## Prerequisites
To get most out of this tutorial you should already have a basic understanding of the following.
- [Python][python]
Also you need to have the following installed.
- [Python][python]
- [Pip][pip-url]
- [CPL](setup)
- [CPL-CLI](setup)
## Create the project
To create the sample project to the following:
1. Open a terminal
2. Run
```sh
cpl new console sample-project
```
3. We don't want to use Application base or Dependency injection:
```sh
Do you want to use application base? (y/n) n
Do you want to use service providing? (y/n) n
```
The ouput should look like this:
```sh
Creating sample-project/LICENSE done
Creating sample-project/README.md done
Creating sample-project/src/tests/__init__.py done
Creating sample-project/appsettings.json done
Creating sample-project/src/sample-project/__init__.py done
Creating sample-project/src/sample-projectmain.py done
```
4. Open the project with an IDE like VS Code or PyCharm
![IDE](images/ide.png)
5. Set the 'src' directory as source folder
![IDE set src folder](images/ide-src.png)
6. Run the application
You should see an output like:
```sh
Hello World
```
7. In PyCharm you have to enable ```Emulate terminal in output console```!
![IDE emulate console](images/ide-emulate.png)
## Create a menu
1. Open the 'sample-project/main.py'
2. Change 'Hello World' to 'Password generator:' in line 5
3. Add ```Console.select``` as follows:
```py
from cpl.console import Console
def main():
Console.write_line('Password generator:')
options = [
'Only lower case',
'Only upper case',
'Lower and upper case'
'Exit'
]
option = Console.select('>', 'Select option: ', options)
if __name__ == '__main__':
main()
```
4. Get Id of the selected option:
```py
index = options.index(option)
```
5. Create the generate function as follows:
```py
def generate_password(letters: str, length: int) -> str:
return ''.join(random.choice(letters) for i in range(length))
```
Add imports:
```py
import random
import string
```
6. Get length of the password:
```py
length = int(Console.read('Length: '))
```
7. Validate the selected option:
```py
index = options.index(option)
letters = ''
if index == 0:
letters = string.ascii_lowercase
elif index == 1:
letters = string.ascii_uppercase
elif index == 2:
letters = string.ascii_letters
elif index == len(options) - 1:
exit()
```
8. Print the generated password:
```py
Console.write_line('Password: ', generate_password(letters, length))
```
9. The full 'sample-project/main.py':
```py
import random
import string
from cpl.console import Console
def generate_password(letters: str, length: int) -> str:
return ''.join(random.choice(letters) for i in range(length))
def main():
Console.write_line('Password generator:')
options = [
'Only lower case',
'Only upper case',
'Lower and upper case',
'Exit'
]
option = Console.select('>', 'Select option: ', options)
length = int(Console.read('Length: '))
index = options.index(option)
letters = ''
if index == 0:
letters = string.ascii_lowercase
elif index == 1:
letters = string.ascii_uppercase
elif index == 2:
letters = string.ascii_letters
elif index == len(options) - 1:
exit()
Console.write_line('Password: ', generate_password(letters, length))
if __name__ == '__main__':
main()
```
## What's next
In this section, you've created an application that uses user input to generate a password.
To continue exploring CPL and developing applications:
- [Application base](cpl.application)
- [Dependency injection](cpl.dependency_injection)
- [Console](cpl.console)
<!-- LINKS -->
[pip-url]: https://pip.sh-edraft.de
[python]: https://www.python.org/
[pip]: https://pypi.org/project/pip/

104
docs/build/html/_sources/setup.md.txt vendored Normal file
View File

@ -0,0 +1,104 @@
# Setting up the local environment and workspace
## Table of Contents
1. [Prerequisites](#prerequisites)
2. [Install the package](#install-the-package)
3. [Install the CLI](#install-the-cli)
4. [Create a initial application](#create-initial-console-app)
5. [Create a initial library](#create-initial-library)
6. [Start the application](#start-the-app)
7. [What's next](#whats-next)
## Prerequisites
To get most out of this tutorial you should already have a basic understanding of the following.
- [Python][python]
Also you need to have the following installed.
- [Python][python]
- [Pip][pip-url]
## Install the package
To install the package, open a terminal window and run the following command:
```sh
pip install sh_cpl --extra-index-url https://pip.sh-edraft.de
```
## Install the CLI
You use the CPL CLI to create projects, generate application and library code. You also use the CLI to build and publish your python packages.
To install the CLI, open a terminal window and run the following command:
```sh
pip install sh_cpl-cli --extra-index-url https://pip.sh-edraft.de
```
## Create initial console app
You develop apps and packages in the context of an CPL project which is defined in an cpl.json.
1. Run the CLI command ```cpl new console``` and provide the name my-app, as shown here:
```sh
cpl new console my-app
```
2. The cpl new command prompts you for information about features to include in the initial app. Decline the defaults by enter 'n' and press the Enter key.
The CLI create a new workspace and a simple 'Hello World' app, ready to run.
## Create initial library
You develop apps and packages in the context of an CPL project which is defined in an cpl.json.
1. Run the CLI command ```cpl new library``` and provide the name my-lib, as shown here:
```sh
cpl new library my-lib
```
2. The cpl new command prompts you for information about features to include in the initial library. Decline the defaults by enter 'n' and press the Enter key.
The CLI create a new workspace and a simple 'Hello World' library with CLI, ready to run.
## Start the app
The CLI includes a live development server, so that you can run your app locally.
1. Open a terminal window
2. To navigate to your project workspace, run the following command:
```sh
cd /path/to/project/name
```
3. To run the app run:
```sh
cpl start
```
The ```cpl start``` command launches the server, watches your source files, and restarts the app as you make chnages to thoses source files.
If your installation and setup was successful, you should see a output similar to the following:
```sh
Hello World
```
## What's next
- To learn more about the CPL CLI, see the [CLI Overview](cli.overview)
- Fore more informations about the Pyhton files generated by ```cpl new```, see [New Command](cli.new)
<!-- LINKS -->
[pip-url]: https://pip.sh-edraft.de
[python]: https://www.python.org/
[pip]: https://pypi.org/project/pip/

856
docs/build/html/_static/basic.css vendored Normal file
View File

@ -0,0 +1,856 @@
/*
* basic.css
* ~~~~~~~~~
*
* Sphinx stylesheet -- basic theme.
*
* :copyright: Copyright 2007-2021 by the Sphinx team, see AUTHORS.
* :license: BSD, see LICENSE for details.
*
*/
/* -- main layout ----------------------------------------------------------- */
div.clearer {
clear: both;
}
div.section::after {
display: block;
content: '';
clear: left;
}
/* -- relbar ---------------------------------------------------------------- */
div.related {
width: 100%;
font-size: 90%;
}
div.related h3 {
display: none;
}
div.related ul {
margin: 0;
padding: 0 0 0 10px;
list-style: none;
}
div.related li {
display: inline;
}
div.related li.right {
float: right;
margin-right: 5px;
}
/* -- sidebar --------------------------------------------------------------- */
div.sphinxsidebarwrapper {
padding: 10px 5px 0 10px;
}
div.sphinxsidebar {
float: left;
width: 230px;
margin-left: -100%;
font-size: 90%;
word-wrap: break-word;
overflow-wrap : break-word;
}
div.sphinxsidebar ul {
list-style: none;
}
div.sphinxsidebar ul ul,
div.sphinxsidebar ul.want-points {
margin-left: 20px;
list-style: square;
}
div.sphinxsidebar ul ul {
margin-top: 0;
margin-bottom: 0;
}
div.sphinxsidebar form {
margin-top: 10px;
}
div.sphinxsidebar input {
border: 1px solid #98dbcc;
font-family: sans-serif;
font-size: 1em;
}
div.sphinxsidebar #searchbox form.search {
overflow: hidden;
}
div.sphinxsidebar #searchbox input[type="text"] {
float: left;
width: 80%;
padding: 0.25em;
box-sizing: border-box;
}
div.sphinxsidebar #searchbox input[type="submit"] {
float: left;
width: 20%;
border-left: none;
padding: 0.25em;
box-sizing: border-box;
}
img {
border: 0;
max-width: 100%;
}
/* -- search page ----------------------------------------------------------- */
ul.search {
margin: 10px 0 0 20px;
padding: 0;
}
ul.search li {
padding: 5px 0 5px 20px;
background-image: url(file.png);
background-repeat: no-repeat;
background-position: 0 7px;
}
ul.search li a {
font-weight: bold;
}
ul.search li div.context {
color: #888;
margin: 2px 0 0 30px;
text-align: left;
}
ul.keywordmatches li.goodmatch a {
font-weight: bold;
}
/* -- index page ------------------------------------------------------------ */
table.contentstable {
width: 90%;
margin-left: auto;
margin-right: auto;
}
table.contentstable p.biglink {
line-height: 150%;
}
a.biglink {
font-size: 1.3em;
}
span.linkdescr {
font-style: italic;
padding-top: 5px;
font-size: 90%;
}
/* -- general index --------------------------------------------------------- */
table.indextable {
width: 100%;
}
table.indextable td {
text-align: left;
vertical-align: top;
}
table.indextable ul {
margin-top: 0;
margin-bottom: 0;
list-style-type: none;
}
table.indextable > tbody > tr > td > ul {
padding-left: 0em;
}
table.indextable tr.pcap {
height: 10px;
}
table.indextable tr.cap {
margin-top: 10px;
background-color: #f2f2f2;
}
img.toggler {
margin-right: 3px;
margin-top: 3px;
cursor: pointer;
}
div.modindex-jumpbox {
border-top: 1px solid #ddd;
border-bottom: 1px solid #ddd;
margin: 1em 0 1em 0;
padding: 0.4em;
}
div.genindex-jumpbox {
border-top: 1px solid #ddd;
border-bottom: 1px solid #ddd;
margin: 1em 0 1em 0;
padding: 0.4em;
}
/* -- domain module index --------------------------------------------------- */
table.modindextable td {
padding: 2px;
border-collapse: collapse;
}
/* -- general body styles --------------------------------------------------- */
div.body {
min-width: 450px;
max-width: 800px;
}
div.body p, div.body dd, div.body li, div.body blockquote {
-moz-hyphens: auto;
-ms-hyphens: auto;
-webkit-hyphens: auto;
hyphens: auto;
}
a.headerlink {
visibility: hidden;
}
a.brackets:before,
span.brackets > a:before{
content: "[";
}
a.brackets:after,
span.brackets > a:after {
content: "]";
}
h1:hover > a.headerlink,
h2:hover > a.headerlink,
h3:hover > a.headerlink,
h4:hover > a.headerlink,
h5:hover > a.headerlink,
h6:hover > a.headerlink,
dt:hover > a.headerlink,
caption:hover > a.headerlink,
p.caption:hover > a.headerlink,
div.code-block-caption:hover > a.headerlink {
visibility: visible;
}
div.body p.caption {
text-align: inherit;
}
div.body td {
text-align: left;
}
.first {
margin-top: 0 !important;
}
p.rubric {
margin-top: 30px;
font-weight: bold;
}
img.align-left, .figure.align-left, object.align-left {
clear: left;
float: left;
margin-right: 1em;
}
img.align-right, .figure.align-right, object.align-right {
clear: right;
float: right;
margin-left: 1em;
}
img.align-center, .figure.align-center, object.align-center {
display: block;
margin-left: auto;
margin-right: auto;
}
img.align-default, .figure.align-default {
display: block;
margin-left: auto;
margin-right: auto;
}
.align-left {
text-align: left;
}
.align-center {
text-align: center;
}
.align-default {
text-align: center;
}
.align-right {
text-align: right;
}
/* -- sidebars -------------------------------------------------------------- */
div.sidebar {
margin: 0 0 0.5em 1em;
border: 1px solid #ddb;
padding: 7px;
background-color: #ffe;
width: 40%;
float: right;
clear: right;
overflow-x: auto;
}
p.sidebar-title {
font-weight: bold;
}
div.admonition, div.topic, blockquote {
clear: left;
}
/* -- topics ---------------------------------------------------------------- */
div.topic {
border: 1px solid #ccc;
padding: 7px;
margin: 10px 0 10px 0;
}
p.topic-title {
font-size: 1.1em;
font-weight: bold;
margin-top: 10px;
}
/* -- admonitions ----------------------------------------------------------- */
div.admonition {
margin-top: 10px;
margin-bottom: 10px;
padding: 7px;
}
div.admonition dt {
font-weight: bold;
}
p.admonition-title {
margin: 0px 10px 5px 0px;
font-weight: bold;
}
div.body p.centered {
text-align: center;
margin-top: 25px;
}
/* -- content of sidebars/topics/admonitions -------------------------------- */
div.sidebar > :last-child,
div.topic > :last-child,
div.admonition > :last-child {
margin-bottom: 0;
}
div.sidebar::after,
div.topic::after,
div.admonition::after,
blockquote::after {
display: block;
content: '';
clear: both;
}
/* -- tables ---------------------------------------------------------------- */
table.docutils {
margin-top: 10px;
margin-bottom: 10px;
border: 0;
border-collapse: collapse;
}
table.align-center {
margin-left: auto;
margin-right: auto;
}
table.align-default {
margin-left: auto;
margin-right: auto;
}
table caption span.caption-number {
font-style: italic;
}
table caption span.caption-text {
}
table.docutils td, table.docutils th {
padding: 1px 8px 1px 5px;
border-top: 0;
border-left: 0;
border-right: 0;
border-bottom: 1px solid #aaa;
}
table.footnote td, table.footnote th {
border: 0 !important;
}
th {
text-align: left;
padding-right: 5px;
}
table.citation {
border-left: solid 1px gray;
margin-left: 1px;
}
table.citation td {
border-bottom: none;
}
th > :first-child,
td > :first-child {
margin-top: 0px;
}
th > :last-child,
td > :last-child {
margin-bottom: 0px;
}
/* -- figures --------------------------------------------------------------- */
div.figure {
margin: 0.5em;
padding: 0.5em;
}
div.figure p.caption {
padding: 0.3em;
}
div.figure p.caption span.caption-number {
font-style: italic;
}
div.figure p.caption span.caption-text {
}
/* -- field list styles ----------------------------------------------------- */
table.field-list td, table.field-list th {
border: 0 !important;
}
.field-list ul {
margin: 0;
padding-left: 1em;
}
.field-list p {
margin: 0;
}
.field-name {
-moz-hyphens: manual;
-ms-hyphens: manual;
-webkit-hyphens: manual;
hyphens: manual;
}
/* -- hlist styles ---------------------------------------------------------- */
table.hlist {
margin: 1em 0;
}
table.hlist td {
vertical-align: top;
}
/* -- other body styles ----------------------------------------------------- */
ol.arabic {
list-style: decimal;
}
ol.loweralpha {
list-style: lower-alpha;
}
ol.upperalpha {
list-style: upper-alpha;
}
ol.lowerroman {
list-style: lower-roman;
}
ol.upperroman {
list-style: upper-roman;
}
:not(li) > ol > li:first-child > :first-child,
:not(li) > ul > li:first-child > :first-child {
margin-top: 0px;
}
:not(li) > ol > li:last-child > :last-child,
:not(li) > ul > li:last-child > :last-child {
margin-bottom: 0px;
}
ol.simple ol p,
ol.simple ul p,
ul.simple ol p,
ul.simple ul p {
margin-top: 0;
}
ol.simple > li:not(:first-child) > p,
ul.simple > li:not(:first-child) > p {
margin-top: 0;
}
ol.simple p,
ul.simple p {
margin-bottom: 0;
}
dl.footnote > dt,
dl.citation > dt {
float: left;
margin-right: 0.5em;
}
dl.footnote > dd,
dl.citation > dd {
margin-bottom: 0em;
}
dl.footnote > dd:after,
dl.citation > dd:after {
content: "";
clear: both;
}
dl.field-list {
display: grid;
grid-template-columns: fit-content(30%) auto;
}
dl.field-list > dt {
font-weight: bold;
word-break: break-word;
padding-left: 0.5em;
padding-right: 5px;
}
dl.field-list > dt:after {
content: ":";
}
dl.field-list > dd {
padding-left: 0.5em;
margin-top: 0em;
margin-left: 0em;
margin-bottom: 0em;
}
dl {
margin-bottom: 15px;
}
dd > :first-child {
margin-top: 0px;
}
dd ul, dd table {
margin-bottom: 10px;
}
dd {
margin-top: 3px;
margin-bottom: 10px;
margin-left: 30px;
}
dl > dd:last-child,
dl > dd:last-child > :last-child {
margin-bottom: 0;
}
dt:target, span.highlighted {
background-color: #fbe54e;
}
rect.highlighted {
fill: #fbe54e;
}
dl.glossary dt {
font-weight: bold;
font-size: 1.1em;
}
.optional {
font-size: 1.3em;
}
.sig-paren {
font-size: larger;
}
.versionmodified {
font-style: italic;
}
.system-message {
background-color: #fda;
padding: 5px;
border: 3px solid red;
}
.footnote:target {
background-color: #ffa;
}
.line-block {
display: block;
margin-top: 1em;
margin-bottom: 1em;
}
.line-block .line-block {
margin-top: 0;
margin-bottom: 0;
margin-left: 1.5em;
}
.guilabel, .menuselection {
font-family: sans-serif;
}
.accelerator {
text-decoration: underline;
}
.classifier {
font-style: oblique;
}
.classifier:before {
font-style: normal;
margin: 0.5em;
content: ":";
}
abbr, acronym {
border-bottom: dotted 1px;
cursor: help;
}
/* -- code displays --------------------------------------------------------- */
pre {
overflow: auto;
overflow-y: hidden; /* fixes display issues on Chrome browsers */
}
pre, div[class*="highlight-"] {
clear: both;
}
span.pre {
-moz-hyphens: none;
-ms-hyphens: none;
-webkit-hyphens: none;
hyphens: none;
}
div[class*="highlight-"] {
margin: 1em 0;
}
td.linenos pre {
border: 0;
background-color: transparent;
color: #aaa;
}
table.highlighttable {
display: block;
}
table.highlighttable tbody {
display: block;
}
table.highlighttable tr {
display: flex;
}
table.highlighttable td {
margin: 0;
padding: 0;
}
table.highlighttable td.linenos {
padding-right: 0.5em;
}
table.highlighttable td.code {
flex: 1;
overflow: hidden;
}
.highlight .hll {
display: block;
}
div.highlight pre,
table.highlighttable pre {
margin: 0;
}
div.code-block-caption + div {
margin-top: 0;
}
div.code-block-caption {
margin-top: 1em;
padding: 2px 5px;
font-size: small;
}
div.code-block-caption code {
background-color: transparent;
}
table.highlighttable td.linenos,
span.linenos,
div.doctest > div.highlight span.gp { /* gp: Generic.Prompt */
user-select: none;
}
div.code-block-caption span.caption-number {
padding: 0.1em 0.3em;
font-style: italic;
}
div.code-block-caption span.caption-text {
}
div.literal-block-wrapper {
margin: 1em 0;
}
code.descname {
background-color: transparent;
font-weight: bold;
font-size: 1.2em;
}
code.descclassname {
background-color: transparent;
}
code.xref, a code {
background-color: transparent;
font-weight: bold;
}
h1 code, h2 code, h3 code, h4 code, h5 code, h6 code {
background-color: transparent;
}
.viewcode-link {
float: right;
}
.viewcode-back {
float: right;
font-family: sans-serif;
}
div.viewcode-block:target {
margin: -1px -10px;
padding: 0 10px;
}
/* -- math display ---------------------------------------------------------- */
img.math {
vertical-align: middle;
}
div.body div.math p {
text-align: center;
}
span.eqno {
float: right;
}
span.eqno a.headerlink {
position: absolute;
z-index: 1;
}
div.math:hover a.headerlink {
visibility: visible;
}
/* -- printout stylesheet --------------------------------------------------- */
@media print {
div.document,
div.documentwrapper,
div.bodywrapper {
margin: 0 !important;
width: 100%;
}
div.sphinxsidebar,
div.related,
div.footer,
#top-link {
display: none;
}
}

View File

@ -0,0 +1 @@
.fa:before{-webkit-font-smoothing:antialiased}.clearfix{*zoom:1}.clearfix:after,.clearfix:before{display:table;content:""}.clearfix:after{clear:both}@font-face{font-family:FontAwesome;font-style:normal;font-weight:400;src:url(fonts/fontawesome-webfont.eot?674f50d287a8c48dc19ba404d20fe713?#iefix) format("embedded-opentype"),url(fonts/fontawesome-webfont.woff2?af7ae505a9eed503f8b8e6982036873e) format("woff2"),url(fonts/fontawesome-webfont.woff?fee66e712a8a08eef5805a46892932ad) format("woff"),url(fonts/fontawesome-webfont.ttf?b06871f281fee6b241d60582ae9369b9) format("truetype"),url(fonts/fontawesome-webfont.svg?912ec66d7572ff821749319396470bde#FontAwesome) format("svg")}.fa:before{font-family:FontAwesome;font-style:normal;font-weight:400;line-height:1}.fa:before,a .fa{text-decoration:inherit}.fa:before,a .fa,li .fa{display:inline-block}li .fa-large:before{width:1.875em}ul.fas{list-style-type:none;margin-left:2em;text-indent:-.8em}ul.fas li .fa{width:.8em}ul.fas li .fa-large:before{vertical-align:baseline}.fa-book:before,.icon-book:before{content:"\f02d"}.fa-caret-down:before,.icon-caret-down:before{content:"\f0d7"}.fa-caret-up:before,.icon-caret-up:before{content:"\f0d8"}.fa-caret-left:before,.icon-caret-left:before{content:"\f0d9"}.fa-caret-right:before,.icon-caret-right:before{content:"\f0da"}.rst-versions{position:fixed;bottom:0;left:0;width:300px;color:#fcfcfc;background:#1f1d1d;font-family:Lato,proxima-nova,Helvetica Neue,Arial,sans-serif;z-index:400}.rst-versions a{color:#2980b9;text-decoration:none}.rst-versions .rst-badge-small{display:none}.rst-versions .rst-current-version{padding:12px;background-color:#272525;display:block;text-align:right;font-size:90%;cursor:pointer;color:#27ae60}.rst-versions .rst-current-version:after{clear:both;content:"";display:block}.rst-versions .rst-current-version .fa{color:#fcfcfc}.rst-versions .rst-current-version .fa-book,.rst-versions .rst-current-version .icon-book{float:left}.rst-versions .rst-current-version.rst-out-of-date{background-color:#e74c3c;color:#fff}.rst-versions .rst-current-version.rst-active-old-version{background-color:#f1c40f;color:#000}.rst-versions.shift-up{height:auto;max-height:100%;overflow-y:scroll}.rst-versions.shift-up .rst-other-versions{display:block}.rst-versions .rst-other-versions{font-size:90%;padding:12px;color:grey;display:none}.rst-versions .rst-other-versions hr{display:block;height:1px;border:0;margin:20px 0;padding:0;border-top:1px solid #413d3d}.rst-versions .rst-other-versions dd{display:inline-block;margin:0}.rst-versions .rst-other-versions dd a{display:inline-block;padding:6px;color:#fcfcfc}.rst-versions.rst-badge{width:auto;bottom:20px;right:20px;left:auto;border:none;max-width:300px;max-height:90%}.rst-versions.rst-badge .fa-book,.rst-versions.rst-badge .icon-book{float:none;line-height:30px}.rst-versions.rst-badge.shift-up .rst-current-version{text-align:right}.rst-versions.rst-badge.shift-up .rst-current-version .fa-book,.rst-versions.rst-badge.shift-up .rst-current-version .icon-book{float:left}.rst-versions.rst-badge>.rst-current-version{width:auto;height:30px;line-height:30px;padding:0 6px;display:block;text-align:center}@media screen and (max-width:768px){.rst-versions{width:85%;display:none}.rst-versions.shift{display:block}}

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

File diff suppressed because it is too large Load Diff

After

Width:  |  Height:  |  Size: 434 KiB

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

4
docs/build/html/_static/css/theme.css vendored Normal file

File diff suppressed because one or more lines are too long

321
docs/build/html/_static/doctools.js vendored Normal file
View File

@ -0,0 +1,321 @@
/*
* doctools.js
* ~~~~~~~~~~~
*
* Sphinx JavaScript utilities for all documentation.
*
* :copyright: Copyright 2007-2021 by the Sphinx team, see AUTHORS.
* :license: BSD, see LICENSE for details.
*
*/
/**
* select a different prefix for underscore
*/
$u = _.noConflict();
/**
* make the code below compatible with browsers without
* an installed firebug like debugger
if (!window.console || !console.firebug) {
var names = ["log", "debug", "info", "warn", "error", "assert", "dir",
"dirxml", "group", "groupEnd", "time", "timeEnd", "count", "trace",
"profile", "profileEnd"];
window.console = {};
for (var i = 0; i < names.length; ++i)
window.console[names[i]] = function() {};
}
*/
/**
* small helper function to urldecode strings
*
* See https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/decodeURIComponent#Decoding_query_parameters_from_a_URL
*/
jQuery.urldecode = function(x) {
if (!x) {
return x
}
return decodeURIComponent(x.replace(/\+/g, ' '));
};
/**
* small helper function to urlencode strings
*/
jQuery.urlencode = encodeURIComponent;
/**
* This function returns the parsed url parameters of the
* current request. Multiple values per key are supported,
* it will always return arrays of strings for the value parts.
*/
jQuery.getQueryParameters = function(s) {
if (typeof s === 'undefined')
s = document.location.search;
var parts = s.substr(s.indexOf('?') + 1).split('&');
var result = {};
for (var i = 0; i < parts.length; i++) {
var tmp = parts[i].split('=', 2);
var key = jQuery.urldecode(tmp[0]);
var value = jQuery.urldecode(tmp[1]);
if (key in result)
result[key].push(value);
else
result[key] = [value];
}
return result;
};
/**
* highlight a given string on a jquery object by wrapping it in
* span elements with the given class name.
*/
jQuery.fn.highlightText = function(text, className) {
function highlight(node, addItems) {
if (node.nodeType === 3) {
var val = node.nodeValue;
var pos = val.toLowerCase().indexOf(text);
if (pos >= 0 &&
!jQuery(node.parentNode).hasClass(className) &&
!jQuery(node.parentNode).hasClass("nohighlight")) {
var span;
var isInSVG = jQuery(node).closest("body, svg, foreignObject").is("svg");
if (isInSVG) {
span = document.createElementNS("http://www.w3.org/2000/svg", "tspan");
} else {
span = document.createElement("span");
span.className = className;
}
span.appendChild(document.createTextNode(val.substr(pos, text.length)));
node.parentNode.insertBefore(span, node.parentNode.insertBefore(
document.createTextNode(val.substr(pos + text.length)),
node.nextSibling));
node.nodeValue = val.substr(0, pos);
if (isInSVG) {
var rect = document.createElementNS("http://www.w3.org/2000/svg", "rect");
var bbox = node.parentElement.getBBox();
rect.x.baseVal.value = bbox.x;
rect.y.baseVal.value = bbox.y;
rect.width.baseVal.value = bbox.width;
rect.height.baseVal.value = bbox.height;
rect.setAttribute('class', className);
addItems.push({
"parent": node.parentNode,
"target": rect});
}
}
}
else if (!jQuery(node).is("button, select, textarea")) {
jQuery.each(node.childNodes, function() {
highlight(this, addItems);
});
}
}
var addItems = [];
var result = this.each(function() {
highlight(this, addItems);
});
for (var i = 0; i < addItems.length; ++i) {
jQuery(addItems[i].parent).before(addItems[i].target);
}
return result;
};
/*
* backward compatibility for jQuery.browser
* This will be supported until firefox bug is fixed.
*/
if (!jQuery.browser) {
jQuery.uaMatch = function(ua) {
ua = ua.toLowerCase();
var match = /(chrome)[ \/]([\w.]+)/.exec(ua) ||
/(webkit)[ \/]([\w.]+)/.exec(ua) ||
/(opera)(?:.*version|)[ \/]([\w.]+)/.exec(ua) ||
/(msie) ([\w.]+)/.exec(ua) ||
ua.indexOf("compatible") < 0 && /(mozilla)(?:.*? rv:([\w.]+)|)/.exec(ua) ||
[];
return {
browser: match[ 1 ] || "",
version: match[ 2 ] || "0"
};
};
jQuery.browser = {};
jQuery.browser[jQuery.uaMatch(navigator.userAgent).browser] = true;
}
/**
* Small JavaScript module for the documentation.
*/
var Documentation = {
init : function() {
this.fixFirefoxAnchorBug();
this.highlightSearchWords();
this.initIndexTable();
if (DOCUMENTATION_OPTIONS.NAVIGATION_WITH_KEYS) {
this.initOnKeyListeners();
}
},
/**
* i18n support
*/
TRANSLATIONS : {},
PLURAL_EXPR : function(n) { return n === 1 ? 0 : 1; },
LOCALE : 'unknown',
// gettext and ngettext don't access this so that the functions
// can safely bound to a different name (_ = Documentation.gettext)
gettext : function(string) {
var translated = Documentation.TRANSLATIONS[string];
if (typeof translated === 'undefined')
return string;
return (typeof translated === 'string') ? translated : translated[0];
},
ngettext : function(singular, plural, n) {
var translated = Documentation.TRANSLATIONS[singular];
if (typeof translated === 'undefined')
return (n == 1) ? singular : plural;
return translated[Documentation.PLURALEXPR(n)];
},
addTranslations : function(catalog) {
for (var key in catalog.messages)
this.TRANSLATIONS[key] = catalog.messages[key];
this.PLURAL_EXPR = new Function('n', 'return +(' + catalog.plural_expr + ')');
this.LOCALE = catalog.locale;
},
/**
* add context elements like header anchor links
*/
addContextElements : function() {
$('div[id] > :header:first').each(function() {
$('<a class="headerlink">\u00B6</a>').
attr('href', '#' + this.id).
attr('title', _('Permalink to this headline')).
appendTo(this);
});
$('dt[id]').each(function() {
$('<a class="headerlink">\u00B6</a>').
attr('href', '#' + this.id).
attr('title', _('Permalink to this definition')).
appendTo(this);
});
},
/**
* workaround a firefox stupidity
* see: https://bugzilla.mozilla.org/show_bug.cgi?id=645075
*/
fixFirefoxAnchorBug : function() {
if (document.location.hash && $.browser.mozilla)
window.setTimeout(function() {
document.location.href += '';
}, 10);
},
/**
* highlight the search words provided in the url in the text
*/
highlightSearchWords : function() {
var params = $.getQueryParameters();
var terms = (params.highlight) ? params.highlight[0].split(/\s+/) : [];
if (terms.length) {
var body = $('div.body');
if (!body.length) {
body = $('body');
}
window.setTimeout(function() {
$.each(terms, function() {
body.highlightText(this.toLowerCase(), 'highlighted');
});
}, 10);
$('<p class="highlight-link"><a href="javascript:Documentation.' +
'hideSearchWords()">' + _('Hide Search Matches') + '</a></p>')
.appendTo($('#searchbox'));
}
},
/**
* init the domain index toggle buttons
*/
initIndexTable : function() {
var togglers = $('img.toggler').click(function() {
var src = $(this).attr('src');
var idnum = $(this).attr('id').substr(7);
$('tr.cg-' + idnum).toggle();
if (src.substr(-9) === 'minus.png')
$(this).attr('src', src.substr(0, src.length-9) + 'plus.png');
else
$(this).attr('src', src.substr(0, src.length-8) + 'minus.png');
}).css('display', '');
if (DOCUMENTATION_OPTIONS.COLLAPSE_INDEX) {
togglers.click();
}
},
/**
* helper function to hide the search marks again
*/
hideSearchWords : function() {
$('#searchbox .highlight-link').fadeOut(300);
$('span.highlighted').removeClass('highlighted');
},
/**
* make the url absolute
*/
makeURL : function(relativeURL) {
return DOCUMENTATION_OPTIONS.URL_ROOT + '/' + relativeURL;
},
/**
* get the current relative url
*/
getCurrentURL : function() {
var path = document.location.pathname;
var parts = path.split(/\//);
$.each(DOCUMENTATION_OPTIONS.URL_ROOT.split(/\//), function() {
if (this === '..')
parts.pop();
});
var url = parts.join('/');
return path.substring(url.lastIndexOf('/') + 1, path.length - 1);
},
initOnKeyListeners: function() {
$(document).keydown(function(event) {
var activeElementType = document.activeElement.tagName;
// don't navigate when in search box, textarea, dropdown or button
if (activeElementType !== 'TEXTAREA' && activeElementType !== 'INPUT' && activeElementType !== 'SELECT'
&& activeElementType !== 'BUTTON' && !event.altKey && !event.ctrlKey && !event.metaKey
&& !event.shiftKey) {
switch (event.keyCode) {
case 37: // left
var prevHref = $('link[rel="prev"]').prop('href');
if (prevHref) {
window.location.href = prevHref;
return false;
}
case 39: // right
var nextHref = $('link[rel="next"]').prop('href');
if (nextHref) {
window.location.href = nextHref;
return false;
}
}
}
});
}
};
// quick alias for translations
_ = Documentation.gettext;
$(document).ready(function() {
Documentation.init();
});

View File

@ -0,0 +1,12 @@
var DOCUMENTATION_OPTIONS = {
URL_ROOT: document.getElementById("documentation_options").getAttribute('data-url_root'),
VERSION: '',
LANGUAGE: 'None',
COLLAPSE_INDEX: false,
BUILDER: 'html',
FILE_SUFFIX: '.html',
LINK_SUFFIX: '.html',
HAS_SOURCE: true,
SOURCELINK_SUFFIX: '.txt',
NAVIGATION_WITH_KEYS: false
};

BIN
docs/build/html/_static/file.png vendored Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 286 B

Binary file not shown.

Binary file not shown.

Binary file not shown.

Some files were not shown because too many files have changed in this diff Show More