Java 类com.itextpdf.text.html.simpleparser.StyleSheet 实例源码

项目:oStorybook    文件:ExportPDF.java   
@SuppressWarnings("deprecation")
public void HtmlToPdf(String source) {
    StyleSheet styles=null;
    try {
        List<Element> elements = (List<Element>) HTMLWorker.parseToList(new FileReader(source), styles);
        for (Element el : elements) {
            outDoc.add(el);
        }
        File wx=new File(source);
        wx.delete();
    } catch (IOException | DocumentException ex) {
        SbApp.error("ExportPDF.HtmlToPdf("+source+")", ex);
    }
}
项目:SE-410-Project    文件:ExportPDF.java   
@SuppressWarnings("deprecation")
public void HtmlToPdf(String source) {
    StyleSheet styles=null;
    try {
        List<Element> elements = (List<Element>) HTMLWorker.parseToList(new FileReader(source), styles);
        for (Element el : elements) {
            outDoc.add(el);
        }
        File wx=new File(source);
        wx.delete();
    } catch (IOException | DocumentException ex) {
        SbApp.error("ExportPDF.HtmlToPdf("+source+")", ex);
    }
}