THE BIRT COMPANY THE BIRT COMPANY THE BIRT COMPANY THE BIRT COMPANY THE BIRT COMPANY THE BIRT COMPANY THE BIRT COMPANY THE BIRT COMPANY THE BIRT COMPANY THE BIRT COMPANY THE BIRT COMPANY THE BIRT COMPANY THE BIRT COMPANY THE BIRT

thickbugΛογισμικό & κατασκευή λογ/κού

28 Οκτ 2013 (πριν από 3 χρόνια και 9 μήνες)

230 εμφανίσεις

1

Actuate Corporation © 2010

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

THE

BIRT

COMPANY

2

Actuate Corporation © 2010

Stefan Caracas

BI Professional,
Actuate France

Creating Data Driven Web
Apps with BIRT

3

Actuate Corporation © 2009

Agenda


Introduction


Designing Reports


Designer


APIs


What Now?


BIRT Viewer


Report Engine (Java)


iHub


Plug In 2 BIRT


Spring 2013


Questions

4

Actuate Corporation © 2009

Introduction

5

Actuate Corporation © 2010

Actuate Launches the BIRT Project

AUGUST

2004

Actuate Joins

Eclipse Foundation

as Strategic Developer

and Board Member

Actuate proposed and started

BIRT

B
usiness
I
ntelligence

and
R
eporting
T
ools Project

… a top
-
level Eclipse project

Adds BI and Reporting

as Open Source Project

Professional open source

Primary development resources

funded by Actuate

Contributions from many sources

IBM, Innovent Solutions and community

6

Actuate Corporation © 2010

Simplicity

that makes
simple layouts
easy

Power

to create

very complex

layouts


BIRT


B
usiness
I
ntelligence and
R
eporting
T
ools


Makes all data
-
driven content development easy


Modern, web
-
page design metaphor


Open and standards
-
based


Flexible with rich programmatic control


Full support for libraries and reuse


Foundation for a range of solutions

A New Generation of Data Visualization Technology

7

Actuate Corporation © 2009

Designing Reports

8

Actuate Corporation © 2009

Eclipse Based Designer

9

Actuate Corporation © 2010

BIRT Example Key Capabilities

Very Simple to Very Complex Layouts


Listings, cross
-
tab, dashboard, pixel
-
perfect, charts …


Grouping, advanced aggregations, sub
-
totals, calculations


Multi
-
section and sub
-
reports


Conditional sections and logic


Full programmatic control/scripting


Embedded images…

Comprehensive Data Access


SQL databases, Web Services, Flat
Files, XML,
scripted data sources



Multiple data sources in one design…

Output Formats


HTML, PDF, Excel, Word, PowerPoint…


Internationalization of labels and text


Bi
-
Directional language display

Re
-
use and Developer Productivity


Library support for publishing and
sharing components


Leverages common standards (SQL,
HTML, JavaScript, Java, XML)


Cascading Style Sheets


Built
-
in debugger…

Interactivity and Linking


Data driven hyperlinks


Drill
-
through charts and graphics…

Multiple Usage and Productivity Aids


Graphical layout and design


Query & metadata editors


Formatting Builder


Grouping Builder


Customizable cheat sheets and
templates…

10

Actuate Corporation © 2009

Designing Reports

Quick Designer Tour

11

Actuate Corporation © 2009

APIs

Design Engine API (DE API)
:

Used to create custom reports, create
custom report designer
tools,
or to
explore or modify BIRT report designs
. It can also be called within BIRT
script to modify the report at runtime.
The BIRT Designer is built using this
API.



Chart Engine API (CE API):

Can be used to create and render charts separately from BIRT. It can also
be called in the chart script to modify a chart at runtime.


Data Engine API:

Used
to define
Data
S
ources
and
Data
S
ets
, and to prepare
an
IQueryDefinition
. It can also be used in script to process a Data Set’s data at
runtime.

12

Actuate Corporation © 2009

What Now?

13

Actuate Corporation © 2009

Multiple Deployment Options

BIRT Design




BIRT Engine and APIs


BIRT
onDemand


BIRT
iHub

14

Actuate Corporation © 2009

BIRT Web Viewer

Copy
WebViewerExample

from the
runtime download to the application
server and rename it “
birt


15

Actuate Corporation © 2009

BIRT Web Viewer URLs

With viewer toolbar, pagination, etc.:

http://localhost:8080/birt/frameset?__report=reportName.rptdesign


As a straight HTML output:

http://localhost:8080/birt/run?__report=reportName.rptdesign


Other servlet mappings:

preview, document, output, extract


URL parameters include:

id

title

showtitle

toolbar

navigationbar

locale

format

report

document

parameterpage

pagerange

fittopage

svg

isnull

islocale

masterpage

resourceFolder

bookmark

rtl

page

overwrite

16

Actuate Corporation © 2009

BIRT Web Viewer URLs

Output to PDF:

http://localhost:8080/birt/frameset?__report=reportName.rptdesign&__format
=pdf


To display a single report item as a
reportlet
:

http://localhost:8080/birt/run?__report=reportName.rptdesign&__bookmark=
myTable&__isreportlet=true



17

Actuate Corporation © 2009

BIRT Viewer Tag Library

Example JSP to embed viewer:


<%@ page language="java"
contentType
="text/html; charset=ISO
-
8859
-
1"
pageEncoding
="ISO
-
8859
-
1"%>

<%@
taglib

uri
="/
birt.tld
" prefix="
birt
" %>

<!DOCTYPE html PUBLIC "
-
//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">

<html>


<head>



<meta http
-
equiv
="Content
-
Type" content="text/html; charset=ISO
-
8859
-
1">



<title>My Report
-

JSP</title>


</head>


<body>



<
birt:viewer

id="
birtViewer
"
reportDesign
=“
reportNamerptdesign
"



pattern="frameset"



height="450"



width="700"



format="html"></
birt:viewer
>


</body>

</html>


http://localhost:8080/birt/dashboard.jsp



18

Actuate Corporation © 2009

BIRT Viewer Tag Library

<%@ page language="java"
contentType
="text/html; charset=ISO
-
8859
-
1"

pageEncoding
="ISO
-
8859
-
1"%>

<%@
taglib

uri
="/
birt.tld
" prefix="
birt
" %>

<!DOCTYPE html PUBLIC "
-
//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">

<html>


<
head>



<
meta http
-
equiv
="Content
-
Type" content="text/html; charset=ISO
-
8859
-
1">


</
head>


<
style type="text/
css
">

.


class1
{ background
-
color:#ff0000; color: #
ffffff
; }


</
style>


<
body>




Parameter
Page 1



<
br
>



<
birt:parameterPage




id
="report1"





name
="page1"




reportDesign
="
cascade_report.rptdesign
"




isCustom
="true"




pattern
="frameset">





Cascading
Parameter1: <
birt:paramDef

id="5" name="Country" />




<
br
><
br
>





Cascading
Parameter2: <
birt:paramDef

id="6" name="City"/>




<
br
><
br
>





Cascading
Parameter3: <
birt:paramDef

id="7" name="Customer"
cssClass
="class1"/>




<
br
><
br
>





<
input type="submit" name="submit" value="
Sumbit

form"/>




<
br
><
br
>



</
birt:parameterPage
>



<
br
>


</
body>

</html
>

http://localhost:8080/birt/cascade_report.jsp


19

Actuate Corporation © 2009

Report Engine API (RE API)

static void
executeReport
() throws
EngineException

{


IReportEngine

engine=null;


EngineConfig

config

= null;

try{


config

= new
EngineConfig
( );


config.setLogConfig
("C:
\
\
BIRT_231
\
\
logs",
java.util.logging.Level
.


FINEST);


Platform.startup
(
config

);


IReportEngineFactory

factory = (
IReportEngineFactory
) Platform


.
createFactoryObject
(
IReportEngineFactory.EXTENSION_REPORT
_


ENGINE_FACTORY );


engine =
factory.createReportEngine
(
config

);


IReportRunnable

design = null;


design =
engine.openReportDesign
("C:
\
\
BIRT_231
\
\
designs
\
\
param


.
rptdesign
");


IRunAndRenderTask

task =
engine.createRunAndRenderTask
(design);


task.setParameterValue
("
ordParam
", (new Integer(10101)));


task.validateParameters
();


PDFRenderOption

options = new
PDFRenderOption
();


options.setOutputFileName
("my_report.pdf");


options.setOutputFormat
("
pdf
");


task.setRenderOption
(options);


task.run
();


task.close
();


engine.destroy
();

}catch( Exception ex){


ex.printStackTrace
();

}

finally

{


Platform.shutdown
( );

}

20

Actuate Corporation © 2009

RE API with JSF

public class birt2jsf {



String
executeReport
(String
param
) throws
EngineException


{


IReportEngine

engine=null;


EngineConfig

config

= null;



try{




config

= new
EngineConfig
( );




config.setLogConfig
("/logs",
java.util.logging.Level.FINEST
);



Platform.startup
(
config

);



IReportEngineFactory

factory = (
IReportEngineFactory
) Platform



.
createFactoryObject
(
IReportEngineFactory.EXTENSION_REPORT_ENGINE_FACTORY

);



engine =
factory.createReportEngine
(
config

);





IReportRunnable

design = null;



design =
engine.openReportDesign
("E:/apache
-
t omcat
-
6.0.36/
webapps
/JSF_2/
t est.rpt design
");



IRunAndRenderTask

task =
engine.createRunAndRenderTask
(design);





task.setParameterValue
("Country",
param
);



task.validatePar ameters
();



HTMLRenderOption

options = new
HTMLRenderOption
();



ByteArrayOutputStream

outs = new
ByteArrayOutput Stream
();



options.setOutputStream
(outs);



options.setImageHandl er
(new
HTMLServerImageHandler
());



options.setBaseImageURL
("images");



options.setImageDirectory
("E:/apache
-
tomcat
-
6.0.36/
webapps
/JSF_2/images");



options.setEmbeddable
(true);



options.setOutputFormat
("ht ml");



task.setRenderOption
(opti ons);



String output;



task.run
();



output =
outs.toString
();



task.close
();



engine.destroy
();



return output;


}catch( Exception ex){



ex.printStackTrace
();



return "Error";


}




finally


{



Platform.shutdown
( );



RegistryProviderFactory.releaseDef ault
();


}


}

}

21

Actuate Corporation © 2009

RE API with JSF

@
ManagedBean
(name="
birtBean
")

@
SessionScoped

public class
BirtBean

implements
Serializable

{



private static final long
serialVersionUID

= 1L;

private String name;


public String
getReport
() {

birt2jsf report =
new birt2jsf( );

String
reportHTML

=
null;

try {

reportHTML

=
report.executeReport
(name);


}
catch (
EngineException

e) {

e.printStackTrace
();

}


return
reportHTML
;

}



public String
getName
() {

return name;

}


public void
setName
(String name) {

this.name = name;

}

}

22

Actuate Corporation © 2009

RE API with JSF

<?xml version="1.0" encoding="UTF
-
8"?><!DOCTYPE html PUBLIC "
-
//W3C//DTD XHTML 1.0
Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1
-
transitional.dtd">

<html
xmlns
="http://www.w3.org/1999/xhtml"

xmlns:f
="http://java.sun.com/
jsf
/core"

xmlns:h
="http://java.sun.com/
jsf
/html">


<
h:head
>



<title>BIRT JSF 2.0 Example</title>


</
h:head
>


<
h:body
>



<h3>Enter Country</h3>




<
h:form
>




<
h:inputText






value="#{birtBean.name}">




</
h:inputText
>




<
h:commandButton

value="View Report" action="page
-
a">



</
h:commandButton
>


<
h:outputText

value="#{
birtBean.report
}" escape="false"/>


</
h:form
>

</
h:body
></html>

http://localhost:8080/JSF_2/page
-
a.jsf







http://localhost:8080/JSF_2/page
-
a.jsf

23

Actuate Corporation © 2009

iHub

and JSAPI

<html>

<head>

<script type="text/
javascript
" language="JavaScript"
src
="http://localhost:8900/
ActuateJavaComponent
/
jsapi
"></script>

</head>

<body
onload
="
init
();">


<h1>Simple Viewer</h1>



<div id="
myDivContainer
" style="border
-
width: 1px; border
-
style: solid;"></div>



<script type="text/
javascript
" language="JavaScript">



var

myViewer
;



function
init
(){




actuate.load
("viewer");




actuate.initialize
( "http://
localhost:8900/
iportal
/",
null, null, null,
createViewer

);



}



function
createViewer
(){




myViewer

= new
actuate.Viewer
( "
myDivContainer
" );




myViewer.setReportName
("/
Mashup
/
QuickReport.rptdesign
" );




myViewer.submit
();



}


</script>

</body>

</html>

24

Actuate Corporation © 2009

Plug In 2 BIRT


Spring 2013

Contest runs from March 28, 2013 to April 30, 2013


Plug
-
In Categories

Open Data Access (ODA) Drivers

Output Emitters

Report Item Extensions

Chart Extensions


New
iPad

for Top 3 Plug
-
Ins!






Visit BIRT Exchange for full contest details

25

Actuate Corporation © 2009

Questions?

26

Actuate Corporation © 2010

Downloads and Getting Started

BIRT Exchange Community Site

Centralized hub for BIRT developers


Access demos, tutorials, tips and techniques, documentation…


Enables developers to be more productive and build applications faster


Marketplace for applications

Explore


Search/sort


Rate, comment


Forums

Download


Documentation


Software


Examples

Contribute


BIRT designs, code


Technical tips


Applications

www.birt
-
exchange.org