anki.exporting#
Classes#
Functions#
|
Module Contents#
- class anki.exporting.Exporter(col: anki.collection.Collection, did: anki.decks.DeckId | None = None, cids: list[anki.cards.CardId] | None = None)#
- includeHTML: bool | None = None#
- ext: str | None = None#
- includeTags: bool | None = None#
- includeSched: bool | None = None#
- includeMedia: bool | None = None#
- col#
- did = None#
- cids = None#
- static key(col: anki.collection.Collection) str#
- doExport(path) None#
- exportInto(path: str) None#
- processText(text: str) str#
- escapeText(text: str) str#
Escape newlines, tabs, CSS and quotechar.
- stripHTML(text: str) str#
- cardIds() Any#
- class anki.exporting.TextCardExporter(col)#
Bases:
Exporter- ext = '.txt'#
- includeHTML = True#
- static key(col: anki.collection.Collection) str#
- doExport(file) None#
- class anki.exporting.TextNoteExporter(col: anki.collection.Collection)#
Bases:
Exporter- ext = '.txt'#
- includeTags = True#
- includeHTML = True#
- includeID = False#
- static key(col: anki.collection.Collection) str#
- doExport(file: io.BufferedWriter) None#
- class anki.exporting.AnkiExporter(col: anki.collection.Collection)#
Bases:
Exporter- ext = '.anki2'#
- includeSched: bool | None = False#
- includeMedia = True#
- static key(col: anki.collection.Collection) str#
- deckIds() list[anki.decks.DeckId]#
- exportInto(path: str) None#
- postExport() None#
- removeSystemTags(tags: str) str#
- class anki.exporting.AnkiPackageExporter(col: anki.collection.Collection)#
Bases:
AnkiExporter- ext = '.apkg'#
- static key(col: anki.collection.Collection) str#
- exportInto(path: str) None#
- doExport(z: zipfile.ZipFile, path: str) dict[str, str]#
- prepareMedia() None#
- class anki.exporting.AnkiCollectionPackageExporter(col)#
Bases:
AnkiPackageExporter- ext = '.colpkg'#
- verbatim = True#
- includeSched = None#
- LEGACY = True#
- static key(col: anki.collection.Collection) str#
- exportInto(path: str) None#
Export collection. Caller must re-open afterwards.
- class anki.exporting.AnkiCollectionPackage21bExporter(col)#
Bases:
AnkiCollectionPackageExporter- LEGACY = False#
- static key(_col: anki.collection.Collection) str#
- anki.exporting.exporters(col: anki.collection.Collection) list[tuple[str, Any]]#