Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / ASP.NET / Web Services / April 2007

Tip: Looking for answers? Try searching our database.

Creating multiple namespaces on proxy

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
nyathancha@hotmail.com - 26 Apr 2007 05:21 GMT
Hi,
I am creating some SOAP web services in .net 2.0. The services (and
classes) on the server side live in different namespaces. I was
wondering if there was anyway to preserve the namespace seperation on
the client side (the wsdl proxy thats generated by the microsoft
wsdl.exe tool) and still have the object hierarchy.

For example on the server, I have a base "ServiceRequest" Object which
is under the MyApp.ServiceContracts namespace. This object is
inherited by two different objects which live under different
namespaces. For example a "CreateEmployeeServiceRequest" object which
is under "MyApp.EmployeeServices" and the
"CreateProjectServiceRequest" object which is under
"MyApp.ProjectServices"

I am exposing the services that use these objects through the same web
service, but the problem is that in the proxy the
"CreateEmployeeServiceRequest" and the "CreateProjectServiceRequest"
are under the same namespace (the webreference alias that i specify).

If I expose them through different webservices, they will be under
different namespace and each will inherit from the ServiceRequest
object that is in its namespace, so there is no inheritance
relationship between the two different request objects on the client
side.

So is there anyway to segregate different objects/webmethods into
different namespaces on the client side proxy while still maintaining
the object hierarchy? Does the SOAP specification allow for this?
John Saunders [MVP] - 26 Apr 2007 18:42 GMT
> Hi,
> I am creating some SOAP web services in .net 2.0. The services (and
[quoted text clipped - 25 lines]
> different namespaces on the client side proxy while still maintaining
> the object hierarchy? Does the SOAP specification allow for this?

C# namespaces are one of many platform-specific things which do not travel
to the client through web services. Web Services are meant to be
platform-neutral, so it shouldn't be a surprise to find that they don't
support platform-specific things like namespaces (or constructors, or
indexers, etc.)
Signature


John Saunders [MVP]


Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.