aboutsummaryrefslogtreecommitdiff
path: root/mammoth
diff options
context:
space:
mode:
authorMichael Williamson <mike@zwobble.org>2015-02-07 18:36:19 +0000
committerMichael Williamson <mike@zwobble.org>2015-02-07 18:36:19 +0000
commitbb62d2d8e3865d2eac72f12f6dc09366e811e0b8 (patch)
treed2653ed8da1315e3a6a5597e3aba8090328136ed /mammoth
parent5da998b4fc5c926b25f77eb36ce75c7ec3396cd2 (diff)
Rename html_string to as_string
Diffstat (limited to 'mammoth')
-rw-r--r--mammoth/conversion.py2
-rw-r--r--mammoth/html_generation.py4
2 files changed, 3 insertions, 3 deletions
diff --git a/mammoth/conversion.py b/mammoth/conversion.py
index 922626c..7ea3998 100644
--- a/mammoth/conversion.py
+++ b/mammoth/conversion.py
@@ -28,7 +28,7 @@ def convert_document_element_to_html(element,
id_prefix=id_prefix)
converter.convert_element_to_html(element, html_generator,)
html_generator.end_all()
- return results.Result(html_generator.html_string(), converter.messages)
+ return results.Result(html_generator.as_string(), converter.messages)
class DocumentConverter(object):
diff --git a/mammoth/html_generation.py b/mammoth/html_generation.py
index 9f7930f..f91d4e8 100644
--- a/mammoth/html_generation.py
+++ b/mammoth/html_generation.py
@@ -41,12 +41,12 @@ class HtmlGenerator(object):
self._writer.start(element.name, element.attributes)
def append(self, other):
- other_string = other.html_string()
+ other_string = other.as_string()
if other_string:
self._write_all()
self._writer.append(other_string)
- def html_string(self):
+ def as_string(self):
return self._writer.as_string()