Update Tag exporter code documentation.

This commit is contained in:
MinchinWeb 2015-04-14 11:59:15 -06:00
parent 9ba557c0d3
commit 9950cfecbb

View file

@ -7,18 +7,18 @@ from .util import get_tags_count
class TagExporter(TextExporter):
"""This Exporter can convert entries and journals into json."""
"""This Exporter can lists the tags for entries and journals, exported as a plain text file."""
names = ["tags"]
extension = "tags"
@classmethod
def export_entry(cls, entry):
"""Returns a markdown representation of a single entry."""
"""Returns a list of tags for a single entry."""
return ", ".join(entry.tags)
@classmethod
def export_journal(cls, journal):
"""Returns a json representation of an entire journal."""
"""Returns a list of tags and their frequency for an entire journal."""
tag_counts = get_tags_count(journal)
result = ""
if not tag_counts: