templates-project_setup/python/template-module.py

49 lines
888 B
Python

"""
TODO This is just an example of a module docstring. Explain what this module
does at this place.
"""
import logging
LOGGER = logging.getLogger(__name__)
class MyClass:
"""
Put a short explanation of this class here.
Attributes:
public_param: Some publicly accessible parameter
"""
_private_param: str
public_param: int
def __init__(self, param1):
"""
The constructor for MyClass.
Parameters:
param1: Description of param1
"""
_private_param = param1
def my_function(param1: int) -> int:
"""
Summary line.
Extended description of function.
Parameters:
param1: Description of param1
Returns:
Description of return value
"""
return param1 * 5
if __name__ == "__main__":
LOGGER.error("do not run this on it's own")