I'amは、現在のチュートリアル(http://kristantohans.wordpress.com/2010/03/01/new-to-jasperreport-build-your-first-impressive-application-part-2/) に従い、彼はどのように私はここにモンゴへの接続を行うことができますJavaのDB接続(CONN)JasperFillManager.fillReportとmongo?
50 try {
51 //Fill the report with parameter, connection and the stream reader
52 JasperPrint jp = JasperFillManager.fillReport(is, null, conn);
を使うのか? 私が持っているモンゴであるので:
Mongo m = new Mongo("localhost" , 27017);
DB db = m.getDB("test");
と
JasperPrint jp = JasperFillManager.fillReport(is, null, m);
おかげで動作しません!
を訪問するが、ここで答え:http://stackoverflow.com/questions/9332373/generatepdf-with-jasperreports-library-and-mongodb – mdahlman