「jasper/demo/hsqldb/build.xml」を右クリックし「Run As → 1 Ant Build」を選択。
日本語環境だと「実行 → 1 Ant Build」とかになるかも。
デモ用のHSQLDBを起動しないと、「jasper/demo/sample」配下のサンプルに使うデータが取得できずエラーになります。
Buildfile: C:\playworks\jasper\demo\hsqldb\build.xml
runServer:[java][Server@e2291]:[Thread[main,5,main]]: checkRunning(false) entered
[java][Server@e2291]:[Thread[main,5,main]]: checkRunning(false) exited
[java][Server@e2291]: Startup sequence initiated from main() method
[java][Server@e2291]: Loaded properties from [C:\playworks\jasper\demo\hsqldb\server.properties][java][Server@e2291]: Initiating startup sequence...[java][Server@e2291]: Server socket opened successfully in 16 ms.[java][Server@e2291]: Database [index=0, id=0, db=file:test, alias=] opened sucessfully in 718 ms.[java][Server@e2291]: Startup sequence completed in 734 ms.[java][Server@e2291]:2013-01-0103:11:42.687 HSQLDB server 1.8.0 is online
[java][Server@e2291]: To close normally, connect and execute SHUTDOWN SQL
[java][Server@e2291]: From command line,use[Ctrl]+[C] to abort abruptly
6.「sample/jasper」を実行
「jasper/demo/hsqldb/build.xml」を右クリックし「Run As → 1 Ant Build」を選択。
コンソール出力内容
Buildfile: C:\playworks\jasper\demo\samples\jasper\build.xml
test:[echo]===================================[echo] Jasper Sample
[echo]===================================
clean:
clean-sample:
javac:
javac:[mkdir] Created dir: C:\playworks\jasper\demo\samples\jasper\build\classes
[javac] C:\playworks\jasper\demo\samples\build.xml:41: warning:'includeantruntime' was not set, defaulting to build.sysclasspath=last; set to falsefor repeatable builds
[javac] Compiling 1 source file to C:\playworks\jasper\demo\samples\jasper\build\classes
[javac] 警告:[options] ブートストラップ・クラスパスが-source 1.6と一緒に設定されていません
[javac] 注意:C:\playworks\jasper\demo\samples\jasper\src\JasperApp.javaの操作は、未チェックまたは安全ではありません。
[javac] 注意:詳細は、-Xlint:uncheckedオプションを指定して再コンパイルしてください。
[javac] 警告1個
[copy] Copying 2 files to C:\playworks\jasper\demo\samples\jasper\build\classes
compile:
compile:[mkdir] Created dir: C:\playworks\jasper\demo\samples\jasper\build\reports
[jrc] Compiling 1 report design files.[jrc]File: C:\playworks\jasper\demo\samples\jasper\reports\FirstJasper.jrxml ... OK.
test:[java] Filling time:8781[java] PDF creation time:3875[java] XML creation time:375[java] XML creation time:110[java] HTML creation time:781[java] RTF creation time:328[java] XLS creation time:2141[java] XLS creation time:1219[java] CSV creation time:62[java] CSV creation time:31[java] XLS creation time:407[java] ODT creation time:875[java] ODS creation time:468[java] DOCX creation time:750[java] XLSX creation time:1203[java] PPTX creation time:422[java] XHTML creation time:328
BUILD SUCCESSFUL
Total time:45 seconds