Skip to main content



      Home
Home » Archived » BIRT » Missing ECore Registry
Missing ECore Registry [message #79918] Fri, 07 October 2005 21:09 Go to next message
Eclipse UserFriend
Originally posted by: jparrott.soe.sony.com

Hi

When attempting to render a chart onto an SWT canvas, I get this error.
Ive added all the BIRT/ECore plugins as dependencies already do no avail.
Anyone know how to fix it? Any info is appreciated.



org.eclipse.emf.ecore.xmi.PackageNotFoundException: Package with uri
'http://www.eclipse.org/birt/2005/design' not found. (test.chart, 3, 69)

at
org.eclipse.emf.ecore.xmi.impl.XMLHandler.getPackageForURI(X MLHandler.java:1730)

at
org.eclipse.emf.ecore.xmi.impl.XMLHandler.getFactoryForPrefi x(XMLHandler.java:1568)

at
org.eclipse.emf.ecore.xmi.impl.XMLHandler.createObjectByType (XMLHandler.java:717)

at
org.eclipse.emf.ecore.xmi.impl.XMLHandler.createTopObject(XM LHandler.java:779)

at
org.eclipse.emf.ecore.xmi.impl.XMLHandler.processElement(XML Handler.java:462)



-Jason
Re: Missing ECore Registry [message #80149 is a reply to message #79918] Mon, 10 October 2005 10:32 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: mpadhye.actuate.com

Hi Jason,

Can you give some contextual details about what you are trying to do?
The exception seems to indicate a problem in de-serializing the chart
model...or an incorrect model resource context.
Are you trying to load a serialized (to disk) version of the chart? If
not, can you try doing this to verify that the model is being correctly
serialized and de-serialized? If the chart is being stored as a
standalone element (not in a BIRT report) the serializer expects an
extension of '.chart' to be used...although the output is regular XML.

If you can attach a snippet of code showing how you are actually
invoking the renderer and chart engine with the model it might help.

Thanks,
Milind

Jason Parrott wrote:
> Hi
>
> When attempting to render a chart onto an SWT canvas, I get this error.
> Ive added all the BIRT/ECore plugins as dependencies already do no avail.
> Anyone know how to fix it? Any info is appreciated.
>
>
>
> org.eclipse.emf.ecore.xmi.PackageNotFoundException: Package with uri
> 'http://www.eclipse.org/birt/2005/design' not found. (test.chart, 3, 69)
>
> at
> org.eclipse.emf.ecore.xmi.impl.XMLHandler.getPackageForURI(X MLHandler.java:1730)
>
> at
> org.eclipse.emf.ecore.xmi.impl.XMLHandler.getFactoryForPrefi x(XMLHandler.java:1568)
>
> at
> org.eclipse.emf.ecore.xmi.impl.XMLHandler.createObjectByType (XMLHandler.java:717)
>
> at
> org.eclipse.emf.ecore.xmi.impl.XMLHandler.createTopObject(XM LHandler.java:779)
>
> at
> org.eclipse.emf.ecore.xmi.impl.XMLHandler.processElement(XML Handler.java:462)
>
>
>
> -Jason
>
>
Re: Missing ECore Registry [message #80162 is a reply to message #80149] Mon, 10 October 2005 14:33 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: jparrott.soe.sony.com

Sure... Im trying to read a chart ive designed in the report designer and am
storing as part of the plugin this is a part of. When deserializing it I am
using:

URL rpt = DroidDashboardPlugin.getDefault().find( new Path(
"reports/chart.rptdesign" ) );

Chart c = ser.read( rpt.openStream() );

It fails in the read call. Stepping through the code it appears that a
package for the http://www.eclipse.org/birt/2005/design is expected by emf.
The code goes into the handleMissingPackage() method in the XMLHandler class
as shown in the stack trace. For some well known package ( such as the
default XML schema namespace ) it has a preset model. Since this is not one
of those, it looks in an element registry. I see that there are several
packages registered in this registry, such as
http://birt.eclipse.org/ChartModel and http://birt.eclipse.org/CHarModelType
However the 2005/design package is not there. DO I have to do something
special to get this one registry or am I barking up the wrong tree? Thanks
for any help..

-Jason

"Milind Padhye" <mpadhye@actuate.com> wrote in message
news:die95b$jpv$1@news.eclipse.org...
> Hi Jason,
>
> Can you give some contextual details about what you are trying to do? The
> exception seems to indicate a problem in de-serializing the chart
> model...or an incorrect model resource context.
> Are you trying to load a serialized (to disk) version of the chart? If
> not, can you try doing this to verify that the model is being correctly
> serialized and de-serialized? If the chart is being stored as a standalone
> element (not in a BIRT report) the serializer expects an extension of
> '.chart' to be used...although the output is regular XML.
>
> If you can attach a snippet of code showing how you are actually invoking
> the renderer and chart engine with the model it might help.
>
> Thanks,
> Milind
>
> Jason Parrott wrote:
>> Hi
>>
>> When attempting to render a chart onto an SWT canvas, I get this error.
>> Ive added all the BIRT/ECore plugins as dependencies already do no avail.
>> Anyone know how to fix it? Any info is appreciated.
>>
>>
>>
>> org.eclipse.emf.ecore.xmi.PackageNotFoundException: Package with uri
>> 'http://www.eclipse.org/birt/2005/design' not found. (test.chart, 3, 69)
>>
>> at
>> org.eclipse.emf.ecore.xmi.impl.XMLHandler.getPackageForURI(X MLHandler.java:1730)
>>
>> at
>> org.eclipse.emf.ecore.xmi.impl.XMLHandler.getFactoryForPrefi x(XMLHandler.java:1568)
>>
>> at
>> org.eclipse.emf.ecore.xmi.impl.XMLHandler.createObjectByType (XMLHandler.java:717)
>>
>> at
>> org.eclipse.emf.ecore.xmi.impl.XMLHandler.createTopObject(XM LHandler.java:779)
>>
>> at
>> org.eclipse.emf.ecore.xmi.impl.XMLHandler.processElement(XML Handler.java:462)
>>
>>
>>
>> -Jason
>>
Re: Missing ECore Registry [message #80299 is a reply to message #80162] Tue, 11 October 2005 10:47 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: mpadhye.actuate.com

Hi Jason,

This explains a lot. (I assume that the 'ser' in your code is a
org.eclipse.birt.chart.model.Serializer instance. You see, the
serializer in the chart library is only intended to serialize and
de-serialize a chart file (created with a .chart extension). It is not
intended to handle de-serialization of a report.

The chart library is a part of BIRT designer but is also intended for
use outside of it. To enable users to save and load generated chart
files, the serializer has been provided.

If you intend to load a report design file, you will need to use the
appropriate API provided by the report engine.

I believe the appropriate API is SessionHandle.openDesign() that
returns a ReportDesignHandle you can use. Please check the Report Engine
API docs for more information.

Hope this helps.

Thanks,
Milind

Jason Parrott wrote:
> Sure... Im trying to read a chart ive designed in the report designer and am
> storing as part of the plugin this is a part of. When deserializing it I am
> using:
>
> URL rpt = DroidDashboardPlugin.getDefault().find( new Path(
> "reports/chart.rptdesign" ) );
>
> Chart c = ser.read( rpt.openStream() );
>
> It fails in the read call. Stepping through the code it appears that a
> package for the http://www.eclipse.org/birt/2005/design is expected by emf.
> The code goes into the handleMissingPackage() method in the XMLHandler class
> as shown in the stack trace. For some well known package ( such as the
> default XML schema namespace ) it has a preset model. Since this is not one
> of those, it looks in an element registry. I see that there are several
> packages registered in this registry, such as
> http://birt.eclipse.org/ChartModel and http://birt.eclipse.org/CHarModelType
> However the 2005/design package is not there. DO I have to do something
> special to get this one registry or am I barking up the wrong tree? Thanks
> for any help..
>
> -Jason
>
> "Milind Padhye" <mpadhye@actuate.com> wrote in message
> news:die95b$jpv$1@news.eclipse.org...
>
>>Hi Jason,
>>
>>Can you give some contextual details about what you are trying to do? The
>>exception seems to indicate a problem in de-serializing the chart
>>model...or an incorrect model resource context.
>>Are you trying to load a serialized (to disk) version of the chart? If
>>not, can you try doing this to verify that the model is being correctly
>>serialized and de-serialized? If the chart is being stored as a standalone
>>element (not in a BIRT report) the serializer expects an extension of
>>'.chart' to be used...although the output is regular XML.
>>
>>If you can attach a snippet of code showing how you are actually invoking
>>the renderer and chart engine with the model it might help.
>>
>>Thanks,
>>Milind
>>
>>Jason Parrott wrote:
>>
>>>Hi
>>>
>>> When attempting to render a chart onto an SWT canvas, I get this error.
>>>Ive added all the BIRT/ECore plugins as dependencies already do no avail.
>>>Anyone know how to fix it? Any info is appreciated.
>>>
>>>
>>>
>>>org.eclipse.emf.ecore.xmi.PackageNotFoundException: Package with uri
>>>'http://www.eclipse.org/birt/2005/design' not found. (test.chart, 3, 69)
>>>
>>> at
>>> org.eclipse.emf.ecore.xmi.impl.XMLHandler.getPackageForURI(X MLHandler.java:1730)
>>>
>>> at
>>> org.eclipse.emf.ecore.xmi.impl.XMLHandler.getFactoryForPrefi x(XMLHandler.java:1568)
>>>
>>> at
>>> org.eclipse.emf.ecore.xmi.impl.XMLHandler.createObjectByType (XMLHandler.java:717)
>>>
>>> at
>>> org.eclipse.emf.ecore.xmi.impl.XMLHandler.createTopObject(XM LHandler.java:779)
>>>
>>> at
>>> org.eclipse.emf.ecore.xmi.impl.XMLHandler.processElement(XML Handler.java:462)
>>>
>>>
>>>
>>>-Jason
>>>
>
>
Re: Missing ECore Registry [message #80363 is a reply to message #80299] Tue, 11 October 2005 21:35 Go to previous messageGo to next message
Eclipse UserFriend
Thanks. That certainly cleared some things up. However, is it not possible
then to use the designer to create and export a model for a chart? My intent
is to design the chart and serialize it to a file which is distributed with
a custom plugin. Later, this serialized file should be read in, data from
the datasource queried, and the result displayed on an swt widget. Ive seen
the example code for doing this on an SWT canvas, which is why I started
down this path. Is this possible at this point?

-Jason

"Milind Padhye" <mpadhye@actuate.com> wrote in message
news:digudn$3u4$1@news.eclipse.org...
> Hi Jason,
>
> This explains a lot. (I assume that the 'ser' in your code is a
> org.eclipse.birt.chart.model.Serializer instance. You see, the serializer
> in the chart library is only intended to serialize and de-serialize a
> chart file (created with a .chart extension). It is not intended to handle
> de-serialization of a report.
>
> The chart library is a part of BIRT designer but is also intended for use
> outside of it. To enable users to save and load generated chart files, the
> serializer has been provided.
>
> If you intend to load a report design file, you will need to use the
> appropriate API provided by the report engine.
>
> I believe the appropriate API is SessionHandle.openDesign() that returns a
> ReportDesignHandle you can use. Please check the Report Engine API docs
> for more information.
>
> Hope this helps.
>
> Thanks,
> Milind
>
> Jason Parrott wrote:
>> Sure... Im trying to read a chart ive designed in the report designer and
>> am storing as part of the plugin this is a part of. When deserializing it
>> I am using:
>>
>> URL rpt = DroidDashboardPlugin.getDefault().find( new Path(
>> "reports/chart.rptdesign" ) );
>>
>> Chart c = ser.read( rpt.openStream() );
>>
>> It fails in the read call. Stepping through the code it appears that a
>> package for the http://www.eclipse.org/birt/2005/design is expected by
>> emf. The code goes into the handleMissingPackage() method in the
>> XMLHandler class as shown in the stack trace. For some well known package
>> ( such as the default XML schema namespace ) it has a preset model. Since
>> this is not one of those, it looks in an element registry. I see that
>> there are several packages registered in this registry, such as
>> http://birt.eclipse.org/ChartModel and
>> http://birt.eclipse.org/CHarModelType However the 2005/design package is
>> not there. DO I have to do something special to get this one registry or
>> am I barking up the wrong tree? Thanks for any help..
>>
>> -Jason
>>
>> "Milind Padhye" <mpadhye@actuate.com> wrote in message
>> news:die95b$jpv$1@news.eclipse.org...
>>
>>>Hi Jason,
>>>
>>>Can you give some contextual details about what you are trying to do? The
>>>exception seems to indicate a problem in de-serializing the chart
>>>model...or an incorrect model resource context.
>>>Are you trying to load a serialized (to disk) version of the chart? If
>>>not, can you try doing this to verify that the model is being correctly
>>>serialized and de-serialized? If the chart is being stored as a
>>>standalone element (not in a BIRT report) the serializer expects an
>>>extension of '.chart' to be used...although the output is regular XML.
>>>
>>>If you can attach a snippet of code showing how you are actually invoking
>>>the renderer and chart engine with the model it might help.
>>>
>>>Thanks,
>>>Milind
>>>
>>>Jason Parrott wrote:
>>>
>>>>Hi
>>>>
>>>> When attempting to render a chart onto an SWT canvas, I get this
>>>> error. Ive added all the BIRT/ECore plugins as dependencies already do
>>>> no avail. Anyone know how to fix it? Any info is appreciated.
>>>>
>>>>
>>>>
>>>>org.eclipse.emf.ecore.xmi.PackageNotFoundException: Package with uri
>>>>'http://www.eclipse.org/birt/2005/design' not found. (test.chart, 3, 69)
>>>>
>>>> at
>>>> org.eclipse.emf.ecore.xmi.impl.XMLHandler.getPackageForURI(X MLHandler.java:1730)
>>>>
>>>> at
>>>> org.eclipse.emf.ecore.xmi.impl.XMLHandler.getFactoryForPrefi x(XMLHandler.java:1568)
>>>>
>>>> at
>>>> org.eclipse.emf.ecore.xmi.impl.XMLHandler.createObjectByType (XMLHandler.java:717)
>>>>
>>>> at
>>>> org.eclipse.emf.ecore.xmi.impl.XMLHandler.createTopObject(XM LHandler.java:779)
>>>>
>>>> at
>>>> org.eclipse.emf.ecore.xmi.impl.XMLHandler.processElement(XML Handler.java:462)
>>>>
>>>>
>>>>
>>>>-Jason
>>>>
>>
Re: Missing ECore Registry [message #80815 is a reply to message #80363] Thu, 13 October 2005 16:00 Go to previous message
Eclipse UserFriend
Originally posted by: mpadhye.actuate.com

Hi Jason,

If by by 'designer' you mean the BIRT report designer, the answer is
simply 'No'...that is not possible. If on the other hand, you mean the
chart builder, there is no UI provided in the builder to save a chart
model to disk but there are ways to do this from the invoking class.

The chart builder UI is intended to be used as part of a separate
application that would handle the serialization / de-serialization of
the chart to disk if required. It is expected that if the chart library
is being used embedded in another application, the integrator would want
to embed the chart into the application's own document rather than store
it as a separate file.

It would be a fairly straightforward task to serialize the chart model
created by the builder. You could do this wherever you invoked the chart
builder from. You could use the 'getChart()' method to get the model and
serialize it using a Serializer instance.

Thanks,
Milind

Jason Parrott wrote:
> Thanks. That certainly cleared some things up. However, is it not possible
> then to use the designer to create and export a model for a chart? My intent
> is to design the chart and serialize it to a file which is distributed with
> a custom plugin. Later, this serialized file should be read in, data from
> the datasource queried, and the result displayed on an swt widget. Ive seen
> the example code for doing this on an SWT canvas, which is why I started
> down this path. Is this possible at this point?
>
> -Jason
>
> "Milind Padhye" <mpadhye@actuate.com> wrote in message
> news:digudn$3u4$1@news.eclipse.org...
>
>>Hi Jason,
>>
>>This explains a lot. (I assume that the 'ser' in your code is a
>>org.eclipse.birt.chart.model.Serializer instance. You see, the serializer
>>in the chart library is only intended to serialize and de-serialize a
>>chart file (created with a .chart extension). It is not intended to handle
>>de-serialization of a report.
>>
>>The chart library is a part of BIRT designer but is also intended for use
>>outside of it. To enable users to save and load generated chart files, the
>>serializer has been provided.
>>
>>If you intend to load a report design file, you will need to use the
>>appropriate API provided by the report engine.
>>
>>I believe the appropriate API is SessionHandle.openDesign() that returns a
>>ReportDesignHandle you can use. Please check the Report Engine API docs
>>for more information.
>>
>>Hope this helps.
>>
>>Thanks,
>>Milind
>>
>>Jason Parrott wrote:
>>
>>>Sure... Im trying to read a chart ive designed in the report designer and
>>>am storing as part of the plugin this is a part of. When deserializing it
>>>I am using:
>>>
>>>URL rpt = DroidDashboardPlugin.getDefault().find( new Path(
>>>"reports/chart.rptdesign" ) );
>>>
>>>Chart c = ser.read( rpt.openStream() );
>>>
>>>It fails in the read call. Stepping through the code it appears that a
>>>package for the http://www.eclipse.org/birt/2005/design is expected by
>>>emf. The code goes into the handleMissingPackage() method in the
>>>XMLHandler class as shown in the stack trace. For some well known package
>>>( such as the default XML schema namespace ) it has a preset model. Since
>>>this is not one of those, it looks in an element registry. I see that
>>>there are several packages registered in this registry, such as
>>>http://birt.eclipse.org/ChartModel and
>>>http://birt.eclipse.org/CHarModelType However the 2005/design package is
>>>not there. DO I have to do something special to get this one registry or
>>>am I barking up the wrong tree? Thanks for any help..
>>>
>>>-Jason
>>>
>>>"Milind Padhye" <mpadhye@actuate.com> wrote in message
>>>news:die95b$jpv$1@news.eclipse.org...
>>>
>>>
>>>>Hi Jason,
>>>>
>>>>Can you give some contextual details about what you are trying to do? The
>>>>exception seems to indicate a problem in de-serializing the chart
>>>>model...or an incorrect model resource context.
>>>>Are you trying to load a serialized (to disk) version of the chart? If
>>>>not, can you try doing this to verify that the model is being correctly
>>>>serialized and de-serialized? If the chart is being stored as a
>>>>standalone element (not in a BIRT report) the serializer expects an
>>>>extension of '.chart' to be used...although the output is regular XML.
>>>>
>>>>If you can attach a snippet of code showing how you are actually invoking
>>>>the renderer and chart engine with the model it might help.
>>>>
>>>>Thanks,
>>>>Milind
>>>>
>>>>Jason Parrott wrote:
>>>>
>>>>
>>>>>Hi
>>>>>
>>>>> When attempting to render a chart onto an SWT canvas, I get this
>>>>>error. Ive added all the BIRT/ECore plugins as dependencies already do
>>>>>no avail. Anyone know how to fix it? Any info is appreciated.
>>>>>
>>>>>
>>>>>
>>>>>org.eclipse.emf.ecore.xmi.PackageNotFoundException: Package with uri
>>>>>'http://www.eclipse.org/birt/2005/design' not found. (test.chart, 3, 69)
>>>>>
>>>>> at
>>>>> org.eclipse.emf.ecore.xmi.impl.XMLHandler.getPackageForURI(X MLHandler.java:1730)
>>>>>
>>>>> at
>>>>> org.eclipse.emf.ecore.xmi.impl.XMLHandler.getFactoryForPrefi x(XMLHandler.java:1568)
>>>>>
>>>>> at
>>>>> org.eclipse.emf.ecore.xmi.impl.XMLHandler.createObjectByType (XMLHandler.java:717)
>>>>>
>>>>> at
>>>>> org.eclipse.emf.ecore.xmi.impl.XMLHandler.createTopObject(XM LHandler.java:779)
>>>>>
>>>>> at
>>>>> org.eclipse.emf.ecore.xmi.impl.XMLHandler.processElement(XML Handler.java:462)
>>>>>
>>>>>
>>>>>
>>>>>-Jason
>>>>>
>>>
>
Previous Topic:Setting Page layout.
Next Topic:Unable to checkout CVS as anonymous user
Goto Forum:
  


Current Time: Wed Jul 16 21:58:34 EDT 2025

Powered by FUDForum. Page generated in 0.60443 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top