Skip to content

Commit

Permalink
kml.KML documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
cleder committed Nov 18, 2024
1 parent d8d28e8 commit e980d5f
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 18 deletions.
18 changes: 9 additions & 9 deletions docs/fastkml.rst
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,15 @@ Reference Guide

.. automodule:: fastkml

fastkml.kml
------------------

.. automodule:: fastkml.kml
:members:
:undoc-members:
:show-inheritance:


fastkml.base
-------------------

Expand Down Expand Up @@ -133,15 +142,6 @@ fastkml.gx
:undoc-members:
:show-inheritance:

fastkml.kml
------------------

.. automodule:: fastkml.kml
:members:
:undoc-members:
:show-inheritance:


fastkml.links
--------------------

Expand Down
12 changes: 3 additions & 9 deletions fastkml/kml.py
Original file line number Diff line number Diff line change
Expand Up @@ -153,12 +153,10 @@ def etree_element(
Return an Element object representing the KML element.
Args:
----
precision (Optional[int]): The precision used for floating-point values.
verbosity (Verbosity): The verbosity level for generating the KML element.
Returns:
-------
Element: The etree Element object representing the KML element.
"""
Expand Down Expand Up @@ -211,14 +209,11 @@ def parse(
Parse a KML file and return a KML object.
Args:
----
file: The file to parse.
Can be a file path (str or Path), or a file-like object.
file: The file to parse. Can be a file path or a file-like object.
Keyword Args:
------------
ns (Optional[str]): The namespace of the KML file.
If not provided, it will be inferred from the root element.
If not provided, it will be inferred from the root element.
name_spaces (Optional[Dict[str, str]]): Additional namespaces.
strict (bool): Whether to enforce strict parsing rules. Defaults to True.
validate (Optional[bool]): Whether to validate the file against the schema.
Expand Down Expand Up @@ -257,10 +252,9 @@ def write(
Write KML to a file.
Args:
----
file_path: The file name where to save the file.
Can be any string value
prettyprint : bool, default=True
prettyprint (bool): default=True
Whether to pretty print the XML.
precision (Optional[int]): The precision used for floating-point values.
verbosity (Verbosity): The verbosity level for generating the KML element.
Expand Down

0 comments on commit e980d5f

Please sign in to comment.