我想解決一個fop問題,我在想從缺省日誌記錄到調試可能會有所幫助。 fop文檔說我需要傳遞messagelevel =「debug」,但是我的ant腳本語法的每個變體都失敗了。我知道這更多是一個螞蟻問題,但我想知道是否有人遇到過這個問題。這裏是我的非工作代碼:在螞蟻腳本中強制執行FOP調試模式的語法
<macrodef name="fop">
<attribute name="in" />
<attribute name="out" />
<sequential>
<java classname="org.apache.fop.cli.Main" fork="true"
failonerror="true">
<arg line="-fo @{in}" />
<arg line="-pdf @{out} messagelevel="debug" />
<arg line="-c ${FopConfig}" />
<classpath>
<pathelement location="${FopBuild}" />
<pathelement location="${FopAvalon}" />
<pathelement location="${FopBatik}" />
<pathelement location="${FopCommonsIo}" />
<pathelement location="${FopCommonsLogging}" />
<pathelement location="${FopFopHyph}" />
<pathelement location="${FopJaiCodec}" />
<pathelement location="${FopJaiCore}" />
<pathelement location="${FopSerializer}" />
<pathelement location="${FopXalan}" />
<pathelement location="${FopXerces}" />
<pathelement location="${FopXmlApis}" />
<pathelement location="${FopXmlApisExt}" />
<pathelement location="${FopXmlGraphics}" />
</classpath>
</java>
</sequential>
</macrodef>
I've also tried this, with the arg as a separate line:
<macrodef name="fop">
<attribute name="in" />
<attribute name="out" />
<sequential>
<java classname="org.apache.fop.cli.Main" fork="true"
failonerror="true">
<arg line="-fo @{in}" />
<arg line="-pdf @{out} />
<arg line"messagelevel="debug"" />
<arg line="-c ${FopConfig}" />
<classpath>
<pathelement location="${FopBuild}" />
<pathelement location="${FopAvalon}" />
<pathelement location="${FopBatik}" />
<pathelement location="${FopCommonsIo}" />
<pathelement location="${FopCommonsLogging}" />
<pathelement location="${FopFopHyph}" />
<pathelement location="${FopJaiCodec}" />
<pathelement location="${FopJaiCore}" />
<pathelement location="${FopSerializer}" />
<pathelement location="${FopXalan}" />
<pathelement location="${FopXerces}" />
<pathelement location="${FopXmlApis}" />
<pathelement location="${FopXmlApisExt}" />
<pathelement location="${FopXmlGraphics}" />
</classpath>
</java>
</sequential>
</macrodef>
I'm sure I'm not seeing something simple.
當你說你不同的嘗試都失敗了,那是什麼意思?描述您看到的錯誤消息或不良行爲。 – skrrgwasme 2014-10-08 19:04:32