XMLCommand
#
- class src.pyconverter.xml2py.ast_tree.XMLCommand(filename, refentry, terms, docu_global, version_variables, links, fcache, meta_only=False)#
Bases:
Element
Provides the XML command from the documentation.
Overview#
Beginning of the Python command’s definition. |
|
Python docstring of the command. |
|
Python-formatted notes string. |
|
Python parameter’s string. |
|
Return the Python source. |
|
Return the complete Python definition of the command. |
Source filename of the command. |
|
Command arguments. |
|
Command default. |
|
Argument object list of the command. |
|
Short description of the command. |
|
Name of the XML command. |
|
Python-compatible name. |
|
Flag indicating if the command is archived. |
|
Group of the command. |
|
URL to the Ansys command documentation. |
|
Command filename |
|
Notes of the command. |
Import detail#
from src.pyconverter.xml2py.ast_tree import XMLCommand
Property detail#
- property XMLCommand.xml_filename#
Source filename of the command.
- property XMLCommand.args#
Command arguments.
- property XMLCommand.default#
Command default.
- property XMLCommand.short_desc#
Short description of the command.
- property XMLCommand.name#
Name of the XML command.
- property XMLCommand.py_name#
Python-compatible name.
- property XMLCommand.py_args#
- property XMLCommand.is_archived#
Flag indicating if the command is archived.
- property XMLCommand.group#
Group of the command.
- property XMLCommand.url#
URL to the Ansys command documentation.
- property XMLCommand.filename#
Command filename
- property XMLCommand.notes#
Notes of the command.
Method detail#
- XMLCommand.py_docstring(custom_functions, max_length=100)#
Python docstring of the command.
- XMLCommand.py_notes(max_length=100)#
Python-formatted notes string.
- XMLCommand.__repr__()#
- XMLCommand.py_parm(max_length=100, indent='', links=None, base_url=None, fcache=None)#
Python parameter’s string.
- XMLCommand.py_source(custom_functions=None, indent='')#
Return the Python source.
- Parameters:
- custom_functions: CustomFunctions, optional
Custom functions to add to the command. The default is
None
.
- XMLCommand.to_python(custom_functions=None, indent='')#
Return the complete Python definition of the command.
- Parameters:
- custom_functions: CustomFunctions, optional
Custom functions to add to the command. The default is
None
.- indent: str, optional
Indentation of the Python function. The default is
""
.
- Returns:
str
Python function of the command including the converted docstring.