[Xml-compile] wsdl naming issue.

Nicholas Ellis nicholas.ellis at leadkarma.com
Fri May 31 16:04:10 GMT 2013


Thanks! This did solve the problem of the name not validating.  However I
am still having an issue.  I keep getting the following error.

error: no definitions for `service' found

I read about someone else having issues and the perl monks recommended
using findDef('service'), which I tried along with printIndex(), and
operations().  They all gave the same error.  So it seems I can create the
object but I cannot get it to do anything. Thanks so much for your help!

Cheers,
Nicholas Ellis
Jr. Software Engineer
LeadKarma LLC

On Thu, May 30, 2013 at 6:22 PM, Mark Overmeer <secretaris at nluug.nl> wrote:

> * Nicholas Ellis (nicholas.ellis at leadkarma.com) [130530 19:34]:
> > I am having an issue with the wsdl:service name and wsdl:port name as
> they
> > both start with numbers.  Is there some way to get around the validation
> or
> > patch the schema so this is acceptable.  I got this document from a
> client
> > and cant really change it.
> >
> >         <wsdl:service name=3D"123name">
> >                 <wsdl:port name=3D"123namePort"
>
> I was not aware of it, but you are right: those names need to be
> xsd:NCName.
>
> A pity that the WSDL schema does not abstract that type, because
> that would make it easy to overrule its interpretation.  Now, we
> need more difficult tricks.
>
> You could overwrite XML::Compile::Schema::BuiltInTypes::_ncname()
>
> Cleaner would be to patch the wsdl:
>
>   $wsdl->importDefinition( <<__PATCH )
>   <xs:schema ...>
>   <xs:complexType name=3D"tService">
>     <xs:complexContent>
>       <xs:extension base=3D"wsdl:tExtensibleDocumented">
>         <xs:sequence>
>           <xs:element name=3D"port" type=3D"wsdl:tPort" minOccurs=3D"0"
> maxOccurs=3D"unbounded"/>
>         </xs:sequence>
>         <xs:attribute name=3D"name" type=3D"xs:NMTOKEN" use=3D"required"/>
>       </xs:extension>
>     </xs:complexContent>
>   </xs:complexType>
>   </xs:schema>
>   __PATCH
>
> Or
>
>   $wsdl->importDefinition($patch_file)
> --
> Regards,
>                MarkOv
>
> ------------------------------------------------------------------------
>        Mark Overmeer MSc                                MARKOV Solutions
>        Mark at Overmeer.net                          solutions at overmeer.net
> http://Mark.Overmeer.net                   http://solutions.overmeer.net
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.scsys.co.uk/pipermail/xml-compile/attachments/20130531/2e=
98b5c6/attachment.htm


More information about the Xml-compile mailing list