From 56dad2617a86aeb83cf4f7f56519af621979851d Mon Sep 17 00:00:00 2001 From: Michael Williamson Date: Wed, 24 Feb 2016 21:56:31 +0000 Subject: Use Set instead of List for warnings --- src/main/java/org/zwobble/mammoth/DocumentConverter.java | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) (limited to 'src/main/java/org/zwobble/mammoth/DocumentConverter.java') diff --git a/src/main/java/org/zwobble/mammoth/DocumentConverter.java b/src/main/java/org/zwobble/mammoth/DocumentConverter.java index 76c1901..e11ec8b 100644 --- a/src/main/java/org/zwobble/mammoth/DocumentConverter.java +++ b/src/main/java/org/zwobble/mammoth/DocumentConverter.java @@ -12,9 +12,8 @@ import org.zwobble.mammoth.internal.docx.DocxFile; import org.zwobble.mammoth.internal.docx.InMemoryDocxFile; import org.zwobble.mammoth.internal.docx.ZippedDocxFile; import org.zwobble.mammoth.internal.html.Html; -import org.zwobble.mammoth.internal.styles.DefaultStyles; -import org.zwobble.mammoth.internal.util.Casts; import org.zwobble.mammoth.internal.results.InternalResult; +import org.zwobble.mammoth.internal.util.Casts; import java.io.File; import java.io.IOException; @@ -31,7 +30,7 @@ public class DocumentConverter { private final DocumentToHtmlOptions options; public DocumentConverter() { - this(DocumentToHtmlOptions.DEFAULT.addStyleMap(DefaultStyles.DEFAULT_STYLE_MAP)); + this(DocumentToHtmlOptions.DEFAULT); } private DocumentConverter(DocumentToHtmlOptions options) { @@ -50,6 +49,10 @@ public class DocumentConverter { return new DocumentConverter(options.addStyleMap(styleMap)); } + public DocumentConverter disableDefaultStyleMap() { + return new DocumentConverter(options.disableDefaultStyleMap()); + } + public Result convertToHtml(InputStream stream) throws IOException { return withDocxFile(stream, zipFile -> convertToHtml(Optional.empty(), zipFile)); -- cgit v1.2.3