473,219 Members | 1,659 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,219 software developers and data experts.

can wsdl's choice of class names be changed?

Hi everyone,

I've been going through an article i found on MSDN
concerning designing the messages for a webservice in a schema (xsd) first
and then writing a .wsdl file that imports the schema. Following this i have
used wsdl.exe (that comes with framework 1.1) to generate an abstract class
which my webservice inherits from.

All has gone well with this until i actually looked at my abstract class -
some of the class and variable names do not seem ideal. Essentially I want
to return an xml root element called "SubjectList" which has a number of
"Subject" elements inside it. The XML looks great but wsdl.exe produces a
class with a SubjectList class that has an array of SubjectListSubject
classes called Subject as a member variable. Ideally i would prefer the
"SubjectListSubject" class to be renamed to just "Subject", also i would
like to rename the array to be called "Subjects" instead of "Subject". I
suppose these are just things that would make the proxy more usable. I'm
thinking i could alter the proxy myself but that wouldn't help me when non
..net languages use the wsdl to generate proxies in different languages.

I was hoping there was some additional way i could mark-up the wsdl file or
my xsd schema so wsdl.exe uses the appropriate names?

Sorry for the long post - i've included my wsdl file and xsd schema in case
it helps - also a code snippet showing how it currently looks and how i'd
prefer it to look.



Public Class SubjectList

<System.Xml.Serialization.XmlElementAttribute("Sub ject")> _

Public Subject() As SubjectListSubject


'Public Subjects() As Subject

End Class


Public Class SubjectListSubject


'Public Class Subject

Public ID As String

Public Name As String

<System.Xml.Serialization.XmlElementAttribute(Data Type:="integer")> _

Public SubjectCount As String

<System.Xml.Serialization.XmlElementAttribute(Data Type:="integer")> _

Public DocumentCount As String

End Class

<?xml version="1.0" encoding="utf-8" ?>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"
elementFormDefault="qualified" attributeFormDefault="qualified"
<xs:element name="SubjectListRequest" type="xs:string"></xs:element>
<xs:element name="SubjectList">
<xs:sequence maxOccurs="unbounded">
<xs:element name="Subject">
<xs:element name="ID" type="xs:string"/>
<xs:element name="Name" type="xs:string"/>
<xs:element name="SubjectCount" type="xs:integer"/>
<xs:element name="DocumentCount" type="xs:integer"/>


<?xml version="1.0" encoding="utf-8" ?>




<message name="RequestMessage">
<part name="SubjectLevel" element="s0:SubjectListRequest" />
<message name="ResponseMessage">
<part name="SubjectList" element="s0:SubjectList" />

<portType name="PortTypeName">
<operation name="GetSubjects">
<input message="s0:RequestMessage" />
<output message="s0:ResponseMessage" />

<binding name="SubjectsBase" type="s0:PortTypeName">

<operation name="GetSubjects">
<soap:operation soapAction="http://localhost/BBS/GetSubjects"
style="document" />
<soap:body use="literal"/>
<soap:body use="literal" />
Jun 28 '06 #1
0 1350

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

by: ffhansix | last post by:
Hi, I am having problems with generating a c# proxy class from a IBM websphere WSDL file, when running the wsdl.exe to create the c# proxy file command i recieve an error: Warning: one or...
by: Mike | last post by:
I have a web service being consume by a new client. The WebMethod they are calling is called Process. So in the WSDL I have has 2 elements, Process and ProcessResponse. <s:schema...
by: MyName | last post by:
What is the advantage of a WSDL web service over an API that will be running as an XML engine accessible via an HTTP address over a special port? The client needs to access the API using the HTTP...
by: Ben Crinion | last post by:
Hi im having a few problems consuming a SOAP::Lite web service. I think the problem is actually with the WSDL but im not sure. I have a SOAP::Lite client which works ok using the WSDL (which i...
by: CindyRob | last post by:
Using .NET framework 1.1 SP1, .NET framework SDK 1.1 SP1, Visual Studio .NET 2003, hotfixes 892202 and 823639. I create a proxy class using wsdl.exe, and in the serialized XML request, I see...
by: ScottM | last post by:
I have run into a problem generating the class file via the WSDL utility. I have a WSDL file that was generated by XMLSpy and is able to be read by the Java code utility, but I get the following...
by: John Saunders | last post by:
I don't have time for a reproducer now, but I thought I'd post this and then go vent. I'm very angry. <wsdl:message name="OpSoapIn"> <wsdl:part name="parameters" element="tns:Op"/> ...
by: =?Utf-8?B?TWlnaHR5IE1hcms=?= | last post by:
I'd like to generate my WebService interface from an XSD schema. Here's what I've done: 1. created a XML file 2. use the xsd.exe to generate the XSD: C:\>xsd my.xml 3. my.xsd is generated 4....
by: =?Utf-8?B?S2FydW5ha2Fy?= | last post by:
Hi Everyone, I have reached a dead end in trying to solve the following problem. I have been given this wsdl that is already in operation in production systems throughtout the world (its part...
by: veera ravala | last post by:
ServiceNow is a powerful cloud-based platform that offers a wide range of services to help organizations manage their workflows, operations, and IT services more efficiently. At its core, ServiceNow...
by: VivesProcSPL | last post by:
Obviously, one of the original purposes of SQL is to make data query processing easy. The language uses many English-like terms and syntax in an effort to make it easy to learn, particularly for...
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 3 Jan 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). For other local times, please check World Time Buddy In...
by: jianzs | last post by:
Introduction Cloud-native applications are conventionally identified as those designed and nurtured on cloud infrastructure. Such applications, rooted in cloud technologies, skillfully benefit from...
by: abbasky | last post by:
### Vandf component communication method one: data sharing ​ Vandf components can achieve data exchange through data sharing, state sharing, events, and other methods. Vandf's data exchange method...
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 7 Feb 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:30 (7.30PM). In this month's session, the creator of the excellent VBE...
by: fareedcanada | last post by:
Hello I am trying to split number on their count. suppose i have 121314151617 (12cnt) then number should be split like 12,13,14,15,16,17 and if 11314151617 (11cnt) then should be split like...
by: stefan129 | last post by:
Hey forum members, I'm exploring options for SSL certificates for multiple domains. Has anyone had experience with multi-domain SSL certificates? Any recommendations on reliable providers or specific...
by: MeoLessi9 | last post by:
I have VirtualBox installed on Windows 11 and now I would like to install Kali on a virtual machine. However, on the official website, I see two options: "Installer images" and "Virtual machines"....

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.