When I use freemarker and odt template character " produces a parse exception
Parsing error in template
"fr.opensagres.xdocreport.document.odt.ODTReport@6443226!content.xml" in line
2, column 13050:
Encountered "&", but was expecting one of:
<STRING_LITERAL>
<RAW_STRING>
"false"
"true"
<INTEGER>
<DECIMAL>
"."
"+"
"-"
"!"
"["
"("
"{"
<ID>
at freemarker.core.FMParser.generateParseException(FMParser.java:4672)
at freemarker.core.FMParser.jj_consume_token(FMParser.java:4543)
at freemarker.core.FMParser.UnaryExpression(FMParser.java:340)
at freemarker.core.FMParser.MultiplicativeExpression(FMParser.java:452)
at freemarker.core.FMParser.AdditiveExpression(FMParser.java:402)
at freemarker.core.FMParser.RangeExpression(FMParser.java:573)
at freemarker.core.FMParser.RelationalExpression(FMParser.java:528)
at freemarker.core.FMParser.EqualityExpression(FMParser.java:493)
at freemarker.core.FMParser.AndExpression(FMParser.java:602)
at freemarker.core.FMParser.OrExpression(FMParser.java:625)
at freemarker.core.FMParser.Expression(FMParser.java:238)
at freemarker.core.FMParser.Assign(FMParser.java:1566)
at freemarker.core.FMParser.FreemarkerDirective(FMParser.java:2358)
at freemarker.core.FMParser.Content(FMParser.java:2593)
at freemarker.core.FMParser.OptionalBlock(FMParser.java:2761)
at freemarker.core.FMParser.Root(FMParser.java:2933)
at freemarker.template.Template.<init>(Template.java:193)
at freemarker.cache.TemplateCache.loadTemplate(TemplateCache.java:419)
at freemarker.cache.TemplateCache.getTemplate(TemplateCache.java:330)
at freemarker.cache.TemplateCache.getTemplate(TemplateCache.java:205)
at freemarker.template.Configuration.getTemplate(Configuration.java:740)
at freemarker.template.Configuration.getTemplate(Configuration.java:665)
at fr.opensagres.xdocreport.template.freemarker.FreemarkerTemplateEngine.processWithCache(FreemarkerTemplateEngine.java:110)
at fr.opensagres.xdocreport.template.AbstractTemplateEngine.process(AbstractTemplateEngine.java:112)
at fr.opensagres.xdocreport.template.AbstractTemplateEngine.process(AbstractTemplateEngine.java:83)
at fr.opensagres.xdocreport.document.AbstractXDocReport.processTemplateEngine(AbstractXDocReport.java:775)
at fr.opensagres.xdocreport.document.AbstractXDocReport.process(AbstractXDocReport.java:521)
at fr.opensagres.xdocreport.document.AbstractXDocReport.process(AbstractXDocReport.java:487)
at it.dedagroup.pa.xdocreportadapter.ProcessDocument.processDoc(ProcessDocument.java:39)
at it.dedagroup.pa.xdocreportadapter.ProcessDocument.processDocFreemarkerToXml(ProcessDocument.java:67)
at it.dedagroup.pa.TestODTFreemarker.testProvaODTFreemarker(TestODTFreemarker.java:38)
at it.dedagroup.pa.TestMainGeneric.main(TestMainGeneric.java:8)
I'm using version products:
- Freemarker 2.3.20
- xdocreport (1.0.4 and 1.0.5)
- java 1.6.0.45
- windows 7
- libreoffice 4.4.3.2
I get the same error using conditional operator [#if 'a'=='a']
Thanks
Domenico
Original issue reported on code.google.com by domenico...@gmail.com on 13 Jul 2015 at 10:40
Original issue reported on code.google.com by
domenico...@gmail.com
on 13 Jul 2015 at 10:40Attachments: