lib/TaskJuggler.rb in taskjuggler-0.0.8 vs lib/TaskJuggler.rb in taskjuggler-0.0.9
- old
+ new
@@ -1,11 +1,12 @@
#!/usr/bin/env ruby -w
# encoding: UTF-8
#
# = TaskJuggler.rb -- The TaskJuggler III Project Management Software
#
-# Copyright (c) 2006, 2007, 2008, 2009, 2010 by Chris Schlaeger <cs@kde.org>
+# Copyright (c) 2006, 2007, 2008, 2009, 2010, 2011
+# by Chris Schlaeger <chris@linux.com>
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of version 2 of the GNU General Public License as
# published by the Free Software Foundation.
#
@@ -164,16 +165,17 @@
true
end
# Generate the report with the ID _reportId_. If _regExpMode_ is true,
# _reportId_ is interpreted as a Regular Expression and all reports with
- # matching IDs are generated. _dynamicAtributes_ is a String that may
- # contain attributes to supplement the report definition. The String must be
- # in TJP format and may be nil if no additional attributes are provided.
- def generateReport(reportId, regExpMode, dynamicAttributes = nil)
+ # matching IDs are generated. _formats_ is a list of formats (e. g. :html,
+ # :csv, etc.). _dynamicAtributes_ is a String that may contain attributes to
+ # supplement the report definition. The String must be in TJP format and may
+ # be nil if no additional attributes are provided.
+ def generateReport(reportId, regExpMode, formats, dynamicAttributes = nil)
begin
Log.enter('generateReport', 'Generating report #{reportId} ...')
- @project.generateReport(reportId, regExpMode, dynamicAttributes)
+ @project.generateReport(reportId, regExpMode, formats, dynamicAttributes)
rescue TjException => msg
if msg.message && !msg.message.empty?
@messageHandler.critical('generate_report', msg.message)
end
Log.exit('generateReport')