Update docs

This commit is contained in:
Vinayak Mehta
2018-09-23 14:04:21 +05:30
parent 959a252aa3
commit a70befe528
13 changed files with 93 additions and 121 deletions
+2 -2
View File
@@ -82,7 +82,7 @@ def cli(ctx, *args, **kwargs):
@click.argument("filepath", type=click.Path(exists=True))
@pass_config
def lattice(c, *args, **kwargs):
"""Use lines between text to generate table."""
"""Use lines between text to parse table."""
conf = c.config
pages = conf.pop("pages")
output = conf.pop("output")
@@ -127,7 +127,7 @@ def lattice(c, *args, **kwargs):
@click.argument("filepath", type=click.Path(exists=True))
@pass_config
def stream(c, *args, **kwargs):
"""Use spaces between text to generate table."""
"""Use spaces between text to parse table."""
conf = c.config
pages = conf.pop("pages")
output = conf.pop("output")
+4
View File
@@ -85,6 +85,10 @@ def read_pdf(filepath, pages='1', flavor='lattice', **kwargs):
tables : camelot.core.TableList
"""
if flavor not in ['lattice', 'stream']:
raise NotImplementedError("Unknown flavor specified."
" Use either 'lattice' or 'stream'")
validate_input(kwargs, flavor=flavor)
p = PDFHandler(filepath, pages)
kwargs = remove_extra(kwargs, flavor=flavor)
+1 -1
View File
@@ -21,7 +21,7 @@ logger = setup_logging(__name__)
class Lattice(BaseParser):
"""Lattice method of parsing looks for lines between text
to generate table.
to parse table.
Parameters
----------
+1 -1
View File
@@ -16,7 +16,7 @@ logger = setup_logging(__name__)
class Stream(BaseParser):
"""Stream method of parsing looks for spaces between text
to generate table.
to parse table.
If you want to specify columns when specifying multiple table
areas, make sure that the length of both lists are equal.