2024-01-25 20:34:40 +00:00
|
|
|
from dataclasses import dataclass
|
|
|
|
from typing import Protocol
|
|
|
|
|
2023-08-28 08:28:06 +00:00
|
|
|
import papis.api
|
2024-01-25 20:34:40 +00:00
|
|
|
import papis.commands.edit
|
2023-08-28 08:28:06 +00:00
|
|
|
import papis.config
|
2024-01-25 20:34:40 +00:00
|
|
|
import papis.document
|
|
|
|
import papis.git
|
|
|
|
import papis.logging
|
|
|
|
import papis.notes
|
2023-08-28 08:28:06 +00:00
|
|
|
|
2024-01-25 20:34:40 +00:00
|
|
|
from papis_extract.annotation import Annotation
|
2023-09-19 19:43:19 +00:00
|
|
|
from papis_extract.formatter import Formatter
|
2023-08-28 08:28:06 +00:00
|
|
|
|
|
|
|
logger = papis.logging.get_logger(__name__)
|
|
|
|
|
|
|
|
|
2024-01-25 20:34:40 +00:00
|
|
|
@dataclass
|
|
|
|
class Exporter(Protocol):
|
|
|
|
formatter: Formatter
|
|
|
|
edit: bool = False
|
|
|
|
git: bool = False
|
|
|
|
force: bool = False
|
2023-08-28 08:28:06 +00:00
|
|
|
|
2024-01-25 20:34:40 +00:00
|
|
|
def run(
|
|
|
|
self, annot_docs: list[tuple[papis.document.Document, list[Annotation]]]
|
|
|
|
) -> None:
|
|
|
|
...
|