You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ws.apache.org by "Sagara Gunathunga (JIRA)" <ji...@apache.org> on 2011/02/01 20:12:30 UTC

[jira] Updated: (WODEN-186) Various problems calling toString() on uninitialized *Impl classes

     [ https://issues.apache.org/jira/browse/WODEN-186?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Sagara Gunathunga  updated WODEN-186:
-------------------------------------

    Fix Version/s:     (was: M9)
                   1.0

> Various problems calling toString() on uninitialized *Impl classes
> ------------------------------------------------------------------
>
>                 Key: WODEN-186
>                 URL: https://issues.apache.org/jira/browse/WODEN-186
>             Project: Woden
>          Issue Type: Bug
>          Components: Parser
>    Affects Versions: M8
>            Reporter: Jeremy Hughes
>             Fix For: 1.0
>
>
> I'm using the Element API to construct a Description from the ground up, with some problems in calling toString() on uninitialized *Impl objects.
>         WSDLFactory factory = WSDLFactory.newInstance();
>         DescriptionElement descElem1 = factory.newDescription();
>         ServiceElement svcElem1 = descElem1.addServiceElement();
>         assertNotNull(svcElem1.toString());
> gives:
> java.lang.IllegalArgumentException
> 	at org.apache.woden.wsdl20.fragids.ServicePart.<init>(ServicePart.java:40)
> 	at org.apache.woden.internal.wsdl20.ServiceImpl.getFragmentIdentifier(ServiceImpl.java:227)
> 	at org.apache.woden.internal.wsdl20.WSDLComponentImpl.toString(WSDLComponentImpl.java:108)
> ServicePart ctor actually throws a new IllegalArgumentException if passed a null so that's WAD. However, ServiceImpl.toString() should be friendlier.
> Then there is a problem with ElementImpl.toString():
>         WSDLFactory factory = WSDLFactory.newInstance();
>         DescriptionElement descElem1 = factory.newDescription();
>         ServiceElement svcElem1 = descElem1.addServiceElement();
>         EndpointElement endPtElem1 = svcElem1.addEndpointElement();
>         assertNotNull(endPtElem1.toString());
> gives:
> java.lang.NullPointerException
> 	at org.apache.woden.internal.wsdl20.EndpointImpl.getFragmentIdentifier(EndpointImpl.java:140)
> 	at org.apache.woden.internal.wsdl20.WSDLComponentImpl.toString(WSDLComponentImpl.java:108)

-- 
This message is automatically generated by JIRA.
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@ws.apache.org
For additional commands, e-mail: dev-help@ws.apache.org