Skip to content

Commit

Permalink
Added documentation of arguments
Browse files Browse the repository at this point in the history
  • Loading branch information
jesper-friis committed Nov 6, 2024
1 parent 7bff529 commit 56d9773
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion ontopy/ontodoc_rst.py
Original file line number Diff line number Diff line change
Expand Up @@ -194,7 +194,15 @@ def add_header(name):
def add_keyvalue(
key, value, escape=True, htmllink=True, show_figure=True
):
"""Help function for adding a key-value row to table."""
"""Help function for adding a key-value row to table.
Arguments:
key: Key to show in the table.
value: Value to show in the table.
htmllink: Whether to add html link to value.
show_figure: Whether to show figure in value column.
"""
if show_figure and re.match(
r"^https?://[a-zA-Z0-9.+?@/_-]+\.(png|jpg|jpeg|svg|gif)$",
asstring(value, ontology=self.ontology),
Expand Down

0 comments on commit 56d9773

Please sign in to comment.