From 732b896d17a7c69e997f49fa88c466402aa239ab Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Krist=C3=B3f=20T=C3=B3th?= Date: Fri, 27 Jul 2018 14:00:45 +0200 Subject: [PATCH] Add docstrings to YamlFSM --- lib/tfw/fsm/yaml_fsm.py | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/lib/tfw/fsm/yaml_fsm.py b/lib/tfw/fsm/yaml_fsm.py index d6c266d..fbfc542 100644 --- a/lib/tfw/fsm/yaml_fsm.py +++ b/lib/tfw/fsm/yaml_fsm.py @@ -13,7 +13,17 @@ from tfw.fsm.fsm_base import FSMBase class YamlFSM(FSMBase): + """ + This is a state machine capable of building itself from a YAML config file. + """ def __init__(self, config_file, jinja2_variables=None): + """ + :param config_file: path of the YAML file + :param jinja2_variables: dict containing jinja2 variables + or str with filename of YAML file to + parse and use as dict. + jinja2 support is disabled if this is None + """ self.config = ConfigParser(config_file, jinja2_variables).config self.setup_states() super().__init__() # FSMBase.__init__() requires states