Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Archived » XML Schema Definition (XSD) » NPE in XSDAnnotationItemProvider
NPE in XSDAnnotationItemProvider [message #32560] Fri, 31 October 2003 18:54 Go to next message
Lance Phillips is currently offline Lance PhillipsFriend
Messages: 210
Registered: July 2009
Senior Member
This is a multi-part message in MIME format.

------=_NextPart_000_000A_01C39FAE.2B888900
Content-Type: text/plain;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

Ed,
Due to a problem with the way were reading in models, we were =
creating XSDAnnotations with null elements. We haven't quite solved =
that yet, but an interesting side effect is a NPE in the =
XSDAnnotationItemProvider. It would seem that the item provider should =
be a bit more fault tolerant as this exception takes down the property =
sheet page and clutters up the log. Here is the stack...

Oct 31, 2003 12:48:08.062 [main|0] ERROR <com.metamatrix.modeler.ui|0> =
java.lang.NullPointerException

java.lang.NullPointerException
at =
org.eclipse.xsd.provider.XSDAnnotationItemProvider.getText(X SDAnnotationI=
temProvider.java:109)

at =
org.eclipse.emf.edit.provider.AdapterFactoryItemDelegator.ge tText(Adapter=
FactoryItemDelegator.java:93)

at =
org.eclipse.emf.edit.provider.ItemPropertyDescriptor$ItemDel egator.getTex=
t(ItemPropertyDescriptor.java:171)

at =
org.eclipse.emf.edit.ui.provider.PropertyDescriptor$1.getTex t(PropertyDes=
criptor.java:140)...

------=_NextPart_000_000A_01C39FAE.2B888900
Content-Type: text/html;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=3DContent-Type content=3D"text/html; =
charset=3Diso-8859-1">
<META content=3D"MSHTML 6.00.2800.1264" name=3DGENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY>
<DIV><FONT face=3DArial size=3D2>Ed,</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>&nbsp;&nbsp;&nbsp; Due to a problem =
with the way=20
were reading in models, we were creating XSDAnnotations with null=20
elements.&nbsp; We haven't quite solved that yet, but an interesting =
side effect=20
is a NPE in the XSDAnnotationItemProvider.&nbsp; It would seem that the =
item=20
provider should be a bit more fault tolerant as this exception takes =
down the=20
property sheet page and clutters up the log.&nbsp; Here is the=20
stack...</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<P><FONT face=3DArial size=3D2>Oct 31, 2003 12:48:08.062 [main|0] ERROR=20
&lt;com.metamatrix.modeler.ui|0&gt; =
java.lang.NullPointerException</FONT></P>
<DIV><FONT face=3DArial =
size=3D2>java.lang.NullPointerException</FONT></DIV>
<P><FONT face=3DArial size=3D2>at=20
org.eclipse.xsd.provider.XSDAnnotationItemProvider.getText(X SDAnnotationI=
temProvider.java:109)</FONT></P>
<P><FONT face=3DArial size=3D2>at=20
org.eclipse.emf.edit.provider.AdapterFactoryItemDelegator.ge tText(Adapter=
FactoryItemDelegator.java:93)</FONT></P>
<P><FONT face=3DArial size=3D2>at=20
org.eclipse.emf.edit.provider.ItemPropertyDescriptor$ItemDel egator.getTex=
t(ItemPropertyDescriptor.java:171)</FONT></P>
<P><FONT face=3DArial size=3D2>at=20
org.eclipse.emf.edit.ui.provider.PropertyDescriptor$1.getTex t(PropertyDes=
criptor.java:140)...</FONT></P></BODY></HTML>

------=_NextPart_000_000A_01C39FAE.2B888900--
Re: NPE in XSDAnnotationItemProvider [message #32628 is a reply to message #32560] Mon, 03 November 2003 12:46 Go to previous message
Eclipse UserFriend
Originally posted by: merks.ca.ibm.com

--------------71694B39F14BD2205687AFBC
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit

Lance,

I'd be more tempted to prevent null from being added to the list in the
first place...


Lance Phillips wrote:

> Ed, Due to a problem with the way were reading in models, we were
> creating XSDAnnotations with null elements. We haven't quite solved
> that yet, but an interesting side effect is a NPE in the
> XSDAnnotationItemProvider. It would seem that the item provider
> should be a bit more fault tolerant as this exception takes down the
> property sheet page and clutters up the log. Here is the stack... Oct
> 31, 2003 12:48:08.062 [main|0] ERROR <com.metamatrix.modeler.ui|0>
> java.lang.NullPointerExceptionjava.lang.NullPointerException at
> org.eclipse.xsd.provider.XSDAnnotationItemProvider.getText(X SDAnnotationItemProvider.java:109)
>
> at
> org.eclipse.emf.edit.provider.AdapterFactoryItemDelegator.ge tText(AdapterFactoryItemDelegator.java:93)
>
> at
> org.eclipse.emf.edit.provider.ItemPropertyDescriptor$ItemDel egator.getText(ItemPropertyDescriptor.java:171)
>
> at
> org.eclipse.emf.edit.ui.provider.PropertyDescriptor$1.getTex t(PropertyDescriptor.java:140)...

--------------71694B39F14BD2205687AFBC
Content-Type: text/html; charset=us-ascii
Content-Transfer-Encoding: 7bit

<!doctype html public "-//w3c//dtd html 4.0 transitional//en">
<html>
Lance,
<p>I'd be more tempted to prevent null from being added to the list in
the first place...
<br>&nbsp;
<p>Lance Phillips wrote:
<blockquote TYPE=CITE><style></style>
<font face="Arial"><font size=-1>Ed,</font></font><font face="Arial"><font size=-1>&nbsp;&nbsp;&nbsp;
Due to a problem with the way were reading in models, we were creating
XSDAnnotations with null elements.&nbsp; We haven't quite solved that yet,
but an interesting side effect is a NPE in the XSDAnnotationItemProvider.&nbsp;
It would seem that the item provider should be a bit more fault tolerant
as this exception takes down the property sheet page and clutters up the
log.&nbsp; Here is the stack...</font></font>&nbsp;<font face="Arial"><font size=-1>Oct
31, 2003 12:48:08.062 [main|0] ERROR &lt;com.metamatrix.modeler.ui|0> java.lang.NullPointerException</font></font><font face="Arial"><font size=-1>java.lang.NullPointerException</font></font><font face="Arial"><font size=-1>at
org.eclipse.xsd.provider.XSDAnnotationItemProvider.getText(X SDAnnotationItemProvider.java:109) </font></font>
<p><font face="Arial"><font size=-1>at org.eclipse.emf.edit.provider.AdapterFactoryItemDelegator.ge tText(AdapterFactoryItemDelegator.java:93) </font></font>
<p><font face="Arial"><font size=-1>at org.eclipse.emf.edit.provider.ItemPropertyDescriptor$ItemDel egator.getText(ItemPropertyDescriptor.java:171) </font></font>
<p><font face="Arial"><font size=-1>at org.eclipse.emf.edit.ui.provider.PropertyDescriptor$1.getTex t(PropertyDescriptor.java:140)... </font></font></blockquote>
</html>

--------------71694B39F14BD2205687AFBC--
Re: NPE in XSDAnnotationItemProvider [message #580387 is a reply to message #32560] Mon, 03 November 2003 12:46 Go to previous message
Ed Merks is currently offline Ed MerksFriend
Messages: 33113
Registered: July 2009
Senior Member
--------------71694B39F14BD2205687AFBC
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit

Lance,

I'd be more tempted to prevent null from being added to the list in the
first place...


Lance Phillips wrote:

> Ed, Due to a problem with the way were reading in models, we were
> creating XSDAnnotations with null elements. We haven't quite solved
> that yet, but an interesting side effect is a NPE in the
> XSDAnnotationItemProvider. It would seem that the item provider
> should be a bit more fault tolerant as this exception takes down the
> property sheet page and clutters up the log. Here is the stack... Oct
> 31, 2003 12:48:08.062 [main|0] ERROR <com.metamatrix.modeler.ui|0>
> java.lang.NullPointerExceptionjava.lang.NullPointerException at
> org.eclipse.xsd.provider.XSDAnnotationItemProvider.getText(X SDAnnotationItemProvider.java:109)
>
> at
> org.eclipse.emf.edit.provider.AdapterFactoryItemDelegator.ge tText(AdapterFactoryItemDelegator.java:93)
>
> at
> org.eclipse.emf.edit.provider.ItemPropertyDescriptor$ItemDel egator.getText(ItemPropertyDescriptor.java:171)
>
> at
> org.eclipse.emf.edit.ui.provider.PropertyDescriptor$1.getTex t(PropertyDescriptor.java:140)...

--------------71694B39F14BD2205687AFBC
Content-Type: text/html; charset=us-ascii
Content-Transfer-Encoding: 7bit

<!doctype html public "-//w3c//dtd html 4.0 transitional//en">
<html>
Lance,
<p>I'd be more tempted to prevent null from being added to the list in
the first place...
<br>&nbsp;
<p>Lance Phillips wrote:
<blockquote TYPE=CITE><style></style>
<font face="Arial"><font size=-1>Ed,</font></font><font face="Arial"><font size=-1>&nbsp;&nbsp;&nbsp;
Due to a problem with the way were reading in models, we were creating
XSDAnnotations with null elements.&nbsp; We haven't quite solved that yet,
but an interesting side effect is a NPE in the XSDAnnotationItemProvider.&nbsp;
It would seem that the item provider should be a bit more fault tolerant
as this exception takes down the property sheet page and clutters up the
log.&nbsp; Here is the stack...</font></font>&nbsp;<font face="Arial"><font size=-1>Oct
31, 2003 12:48:08.062 [main|0] ERROR &lt;com.metamatrix.modeler.ui|0> java.lang.NullPointerException</font></font><font face="Arial"><font size=-1>java.lang.NullPointerException</font></font><font face="Arial"><font size=-1>at
org.eclipse.xsd.provider.XSDAnnotationItemProvider.getText(X SDAnnotationItemProvider.java:109) </font></font>
<p><font face="Arial"><font size=-1>at org.eclipse.emf.edit.provider.AdapterFactoryItemDelegator.ge tText(AdapterFactoryItemDelegator.java:93) </font></font>
<p><font face="Arial"><font size=-1>at org.eclipse.emf.edit.provider.ItemPropertyDescriptor$ItemDel egator.getText(ItemPropertyDescriptor.java:171) </font></font>
<p><font face="Arial"><font size=-1>at org.eclipse.emf.edit.ui.provider.PropertyDescriptor$1.getTex t(PropertyDescriptor.java:140)... </font></font></blockquote>
</html>

--------------71694B39F14BD2205687AFBC--


Ed Merks
Professional Support: https://www.macromodeling.com/
Previous Topic:progress... but still stuck
Next Topic:XSD ItemProviders should use EMF pattern for creating PropertyDescriptors
Goto Forum:
  


Current Time: Fri Mar 29 05:07:50 GMT 2024

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

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

Back to the top