Skip to content
This repository was archived by the owner on Apr 11, 2025. It is now read-only.

Commit a106761

Browse files
authored
Fixup leftover renaming in documentation (#273)
* Fixup leftover renaming new namespace * Fixup leftover renaming new namespace in api.rst * Fixup leftover renaming new namespace
1 parent 7bb70a7 commit a106761

File tree

2 files changed

+15
-15
lines changed

2 files changed

+15
-15
lines changed

docs/api.rst

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -21,10 +21,10 @@ Lower-Level Classes
2121
.. autoclass:: pypdf_table_extraction.parsers.Lattice
2222
:inherited-members:
2323

24-
.. autoclass:: camelot.parsers.Network
24+
.. autoclass:: pypdf_table_extraction.parsers.Network
2525
:inherited-members:
2626

27-
.. autoclass:: camelot.parsers.Hybrid
27+
.. autoclass:: pypdf_table_extraction.parsers.Hybrid
2828
:inherited-members:
2929

3030
Lower-Lower-Level Classes
@@ -41,7 +41,7 @@ Lower-Lower-Level Classes
4141
Plotting
4242
--------
4343

44-
.. autofunction:: camelot.plot
44+
.. autofunction:: pypdf_table_extraction.plot
4545

46-
.. autoclass:: camelot.plotting.PlotMethods
46+
.. autoclass:: pypdf_table_extraction.plotting.PlotMethods
4747
:inherited-members:

docs/user/quickstart.rst

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ Read the PDF
1616

1717
Reading a PDF to extract tables with pypdf_table_extraction is very simple.
1818

19-
Begin by importing the Camelot module
19+
Begin by importing the pypdf_table_extraction module
2020

2121
.. code-block:: pycon
2222
@@ -34,7 +34,7 @@ Now, let's try to read a PDF. (You can check out the PDF used in this example `h
3434
>>> tables
3535
<TableList n=1>
3636
37-
Now, we have a :class:`TableList <camelot.core.TableList>` object called ``tables``, which is a list of :class:`Table <camelot.core.Table>` objects. We can get everything we need from this object.
37+
Now, we have a :class:`TableList <pypdf_table_extraction.core.TableList>` object called ``tables``, which is a list of :class:`Table <pypdf_table_extraction.core.Table>` objects. We can get everything we need from this object.
3838

3939
We can access each table using its index. From the code snippet above, we can see that the ``tables`` object has only one table, since ``n=1``. Let's access the table using the index ``0`` and take a look at its ``shape``.
4040

@@ -55,7 +55,7 @@ Let's print the parsing report.
5555
'page': 1
5656
}
5757
58-
Woah! The accuracy is top-notch and there is less whitespace, which means the table was most likely extracted correctly. You can access the table as a pandas DataFrame by using the :class:`table <camelot.core.Table>` object's ``df`` property.
58+
Woah! The accuracy is top-notch and there is less whitespace, which means the table was most likely extracted correctly. You can access the table as a pandas DataFrame by using the :class:`table <pypdf_table_extraction.core.Table>` object's ``df`` property.
5959

6060
.. code-block:: pycon
6161
@@ -64,15 +64,15 @@ Woah! The accuracy is top-notch and there is less whitespace, which means the ta
6464
.. csv-table::
6565
:file: ../_static/csv/foo.csv
6666

67-
Looks good! You can now export the table as a CSV file using its :meth:`to_csv() <camelot.core.Table.to_csv>` method. Alternatively you can use :meth:`to_json() <camelot.core.Table.to_json>`, :meth:`to_excel() <camelot.core.Table.to_excel>` :meth:`to_html() <camelot.core.Table.to_html>` :meth:`to_markdown() <camelot.core.Table.to_markdown>` or :meth:`to_sqlite() <camelot.core.Table.to_sqlite>` methods to export the table as JSON, Excel, HTML files or a sqlite database respectively.
67+
Looks good! You can now export the table as a CSV file using its :meth:`to_csv() <pypdf_table_extraction.core.Table.to_csv>` method. Alternatively you can use :meth:`to_json() <pypdf_table_extraction.core.Table.to_json>`, :meth:`to_excel() <pypdf_table_extraction.core.Table.to_excel>` :meth:`to_html() <pypdf_table_extraction.core.Table.to_html>` :meth:`to_markdown() <pypdf_table_extraction.core.Table.to_markdown>` or :meth:`to_sqlite() <pypdf_table_extraction.core.Table.to_sqlite>` methods to export the table as JSON, Excel, HTML files or a sqlite database respectively.
6868

6969
.. code-block:: pycon
7070
7171
>>> tables[0].to_csv('foo.csv')
7272
7373
This will export the table as a CSV file at the path specified. In this case, it is ``foo.csv`` in the current directory.
7474

75-
You can also export all tables at once, using the :class:`tables <camelot.core.TableList>` object's :meth:`export() <camelot.core.TableList.export>` method.
75+
You can also export all tables at once, using the :class:`tables <pypdf_table_extraction.core.TableList>` object's :meth:`export() <pypdf_table_extraction.core.TableList.export>` method.
7676

7777
.. code-block:: pycon
7878
@@ -87,7 +87,7 @@ You can also export all tables at once, using the :class:`tables <camelot.core.T
8787
8888
This will export all tables as CSV files at the path specified. Alternatively, you can use ``f='json'``, ``f='excel'``, ``f='html'``, ``f='markdown'`` or ``f='sqlite'``.
8989

90-
.. note:: The :meth:`export() <camelot.core.TableList.export>` method exports files with a ``page-*-table-*`` suffix. In the example above, the single table in the list will be exported to ``foo-page-1-table-1.csv``. If the list contains multiple tables, multiple CSV files will be created. To avoid filling up your path with multiple files, you can use ``compress=True``, which will create a single ZIP file at your path with all the CSV files.
90+
.. note:: The :meth:`export() <pypdf_table_extraction.core.TableList.export>` method exports files with a ``page-*-table-*`` suffix. In the example above, the single table in the list will be exported to ``foo-page-1-table-1.csv``. If the list contains multiple tables, multiple CSV files will be created. To avoid filling up your path with multiple files, you can use ``compress=True``, which will create a single ZIP file at your path with all the CSV files.
9191

9292
.. note:: pypdf_table_extraction handles rotated PDF pages automatically. As an exercise, try to extract the table out of `this PDF`_.
9393

@@ -98,7 +98,7 @@ Specify page numbers
9898

9999
By default, pypdf_table_extraction only uses the first page of the PDF to extract tables. To specify multiple pages, you can use the ``pages`` keyword argument::
100100

101-
>>> camelot.read_pdf('your.pdf', pages='1,2,3')
101+
>>> pypdf_table_extraction.read_pdf('your.pdf', pages='1,2,3')
102102

103103
.. tip::
104104
Here's how you can do the same with the :ref:`command-line interface <cli>`.
@@ -116,7 +116,7 @@ pypdf_table_extraction supports extracting tables in parrallel using all the ava
116116

117117
.. code-block:: pycon
118118
119-
>>> tables = camelot.read_pdf('foo.pdf', page='all', parallel=True)
119+
>>> tables = pypdf_table_extraction.read_pdf('foo.pdf', page='all', parallel=True)
120120
>>> tables
121121
<TableList n=1>
122122
@@ -133,11 +133,11 @@ pypdf_table_extraction supports extracting tables in parrallel using all the ava
133133
Reading encrypted PDFs
134134
----------------------
135135

136-
To extract tables from encrypted PDF files you must provide a password when calling :meth:`read_pdf() <camelot.read_pdf>`.
136+
To extract tables from encrypted PDF files you must provide a password when calling :meth:`read_pdf() <pypdf_table_extraction.read_pdf>`.
137137

138138
.. code-block:: pycon
139139
140-
>>> tables = camelot.read_pdf('foo.pdf', password='userpass')
140+
>>> tables = pypdf_table_extraction.read_pdf('foo.pdf', password='userpass')
141141
>>> tables
142142
<TableList n=1>
143143
@@ -150,7 +150,7 @@ To extract tables from encrypted PDF files you must provide a password when call
150150
151151
pypdf_table_extraction supports PDFs with all encryption types supported by `pypdf`_. This might require installing PyCryptodome. An exception is thrown if the PDF cannot be read. This may be due to no password being provided, an incorrect password, or an unsupported encryption algorithm.
152152

153-
Further encryption support may be added in future, however in the meantime if your PDF files are using unsupported encryption algorithms you are advised to remove encryption before calling :meth:`read_pdf() <camelot.read_pdf>`. This can been successfully achieved with third-party tools such as `QPDF`_.
153+
Further encryption support may be added in future, however in the meantime if your PDF files are using unsupported encryption algorithms you are advised to remove encryption before calling :meth:`read_pdf() <pypdf_table_extraction.read_pdf>`. This can been successfully achieved with third-party tools such as `QPDF`_.
154154

155155
.. code-block:: console
156156

0 commit comments

Comments
 (0)