开发者

Approach for mapping web service classes to local client classes

开发者 https://www.devze.com 2023-01-14 00:44 出处:网络
I have Java web serivce and .NET client application that consume this web service. W开发者_开发知识库hen we connect to the service we generate service classes (serialization) in our project. But using

I have Java web serivce and .NET client application that consume this web service. W开发者_开发知识库hen we connect to the service we generate service classes (serialization) in our project. But using this web service classes in code directly is wrong approach. I have some ideas about how to create and map my local class to web service class. But I am intertested in how others do the same staff in their applications.

If you have ability pls show your approach in code.

Thank you in advance


I guess you are looking for Facade and Adapter. You will create Facade on your proxy classes the facade will transform service classes to your classes and vice-versa. If you have easy mapping you can use some automatic approach (AutoMapper).

0

精彩评论

暂无评论...
验证码 换一张
取 消