Module documentation_test.documentation_test
Expand source code
import documentation_test.submod1.submod1 as submod1
import documentation_test.submod2.submod2 as submod2
__all__ = ['testFunction', 'testClass']
class testClass(object):
"""Summary of class
Attributes
----------
arg : str
a string to print
"""
def __init__(self, arg: str):
"""Summary of init
Parameters
----------
arg : str, optional
a string to print
"""
super(testClass, self).__init__()
self.arg = arg
@classmethod
def createString(cls, aString: str):
"""create a string
Parameters
----------
aString : str
a string to print
"""
return cls(arg=aString)
def printString(self):
"""Print a string
"""
print(self.arg)
def testFunction(anything: str = 'test') -> None:
"""test function for a demo import of whole module
Parameters
----------
anything : str, optional
a test string
Returns
-------
None
"""
print(anything)
submod1.submod1('string from submod1 in base')
submod2.submod2('string from submod2 in base')
Functions
def testFunction(anything: str = 'test') -> NoneType-
test function for a demo import of whole module
Parameters
anything:str, optional- a test string
Returns
None
Expand source code
def testFunction(anything: str = 'test') -> None: """test function for a demo import of whole module Parameters ---------- anything : str, optional a test string Returns ------- None """ print(anything)
Classes
class testClass (arg: str)-
Summary of class
Attributes
arg:str- a string to print
Summary of init
Parameters
arg:str, optional- a string to print
Expand source code
class testClass(object): """Summary of class Attributes ---------- arg : str a string to print """ def __init__(self, arg: str): """Summary of init Parameters ---------- arg : str, optional a string to print """ super(testClass, self).__init__() self.arg = arg @classmethod def createString(cls, aString: str): """create a string Parameters ---------- aString : str a string to print """ return cls(arg=aString) def printString(self): """Print a string """ print(self.arg)Static methods
def createString(aString: str)-
create a string
Parameters
aString:str- a string to print
Expand source code
@classmethod def createString(cls, aString: str): """create a string Parameters ---------- aString : str a string to print """ return cls(arg=aString)
Methods
def printString(self)-
Print a string
Expand source code
def printString(self): """Print a string """ print(self.arg)