mirror of
https://github.com/MillironX/nfdocs-parser.git
synced 2024-11-24 09:49:56 +00:00
Remove function params_to_list from NFDocs class
Signed-off-by: Thomas A. Christensen II <25492070+MillironX@users.noreply.github.com>
This commit is contained in:
parent
f555cd9c20
commit
f1b695baf9
1 changed files with 20 additions and 20 deletions
|
@ -25,14 +25,7 @@ def definition_type(signature):
|
||||||
# Return the results
|
# Return the results
|
||||||
return def_name, def_type
|
return def_name, def_type
|
||||||
|
|
||||||
class NFDocs(Directive):
|
def params_to_list(params):
|
||||||
# Class default overrides
|
|
||||||
required_arguments = 1
|
|
||||||
|
|
||||||
# Declare the docstring starting characters
|
|
||||||
DOC_STARTER = "/// "
|
|
||||||
|
|
||||||
def params_to_list(self, params):
|
|
||||||
if "tuple" in params.keys():
|
if "tuple" in params.keys():
|
||||||
tuple_item = nodes.list_item()
|
tuple_item = nodes.list_item()
|
||||||
if "name" in params.keys():
|
if "name" in params.keys():
|
||||||
|
@ -40,7 +33,7 @@ class NFDocs(Directive):
|
||||||
tuple_item += nodes.paragraph(text="Tuple:")
|
tuple_item += nodes.paragraph(text="Tuple:")
|
||||||
tuple_list = nodes.bullet_list()
|
tuple_list = nodes.bullet_list()
|
||||||
for io in params["tuple"]:
|
for io in params["tuple"]:
|
||||||
tuple_list += self.params_to_list(io)
|
tuple_list += params_to_list(io)
|
||||||
tuple_item += tuple_list
|
tuple_item += tuple_list
|
||||||
return tuple_item
|
return tuple_item
|
||||||
else:
|
else:
|
||||||
|
@ -51,6 +44,13 @@ class NFDocs(Directive):
|
||||||
io_item += nodes.paragraph(text=params["description"])
|
io_item += nodes.paragraph(text=params["description"])
|
||||||
return io_item
|
return io_item
|
||||||
|
|
||||||
|
class NFDocs(Directive):
|
||||||
|
# Class default overrides
|
||||||
|
required_arguments = 1
|
||||||
|
|
||||||
|
# Declare the docstring starting characters
|
||||||
|
DOC_STARTER = "/// "
|
||||||
|
|
||||||
def run(self):
|
def run(self):
|
||||||
# Take path as single argument for now
|
# Take path as single argument for now
|
||||||
nextflow_path = self.arguments[0]
|
nextflow_path = self.arguments[0]
|
||||||
|
@ -121,7 +121,7 @@ class NFDocs(Directive):
|
||||||
io_section += nodes.title(text=met)
|
io_section += nodes.title(text=met)
|
||||||
io_list = nodes.bullet_list()
|
io_list = nodes.bullet_list()
|
||||||
for io in proc_docs[met]:
|
for io in proc_docs[met]:
|
||||||
io_list += self.params_to_list(io)
|
io_list += params_to_list(io)
|
||||||
io_section += io_list
|
io_section += io_list
|
||||||
proc_section += io_section
|
proc_section += io_section
|
||||||
self.state_machine.document.note_implicit_target(io_section)
|
self.state_machine.document.note_implicit_target(io_section)
|
||||||
|
|
Loading…
Reference in a new issue