Wanderer Posted August 31, 2006 Share Posted August 31, 2006 I have proposition about very small redesign of JRBaseFiller.Subreports in my projects are changing before filling. So, I must preload, change and put subreports into JRBaseFiller.loadedSubreports.I propose to move initialization of the loadedSubreport field into declaration instead of fill() method.E.g. for ver 1.2.5:Change line 247: protected Map loadedSubreports = new HashMap();Exclude line 751: loadedSubreports = new HashMap(); WBR, Wanderer. Link to comment Share on other sites More sharing options...
teodord Posted August 31, 2006 Share Posted August 31, 2006 Hi, I don't think this is needed.The <subreportExpression> can take JasperReport objects as value and you have complete freedom to provide on-the-fly modified versions of such objects if you need to. I hope this helps.Teodor Link to comment Share on other sites More sharing options...
Wanderer Posted August 31, 2006 Author Share Posted August 31, 2006 Hi,Thanks a lot. I omitted this ability. :(As I understood, you propose something like follow:Code:<parametersMapExpression> <![CDATA[$P{REPORT_PARAMETERS_MAP}]]> + $P{SubName}:="sub1.jasper"</parametersMapExpression><subreportExpression class="net.sf.jasperreports.engine.base.JasperReport"> <![CDATA["SubreportCustomizer.class"]]></subreportExpression>Than, in SubreportCustomizer constructor, load and update subreport <$P{SubName}>.Is it right? But, in this case needs dynamic parameter $P{SubName}, because I have few reports which are contain more than one subreports.Can I use $V{SubName} instead of $P{SubName}?Is the $V-map common for report and subreports in contrast to $P-maps? WBR,Wanderer. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now