WSI Basic Profile 1.1 Compliant Web Service!

M

mehdi

Hi folks,
I've been lately trying to expose an object graph (with circular
references) through a web method, however, this was not possible since
the XmlSerializer has got no idea how to address the issue. Therefore,
I've just changed the WebServiceBindingAttribute from

[WebServiceBinding(ConformsTo = WsiProfiles.BasicProfile1_1)]
to
[WebServiceBinding(ConformsTo = WsiProfiles.None)]

and added the SoapDocumentMethodAttribute to the web methods as follows
and the problem is solved.

[SoapDocumentMethod(Use=SoapBindingUse.Encoded)]

The questions:

1. I would like to know this means that I only and only lose the
interoperability? Is this what happens???

2. Is there anyway to solve the circular referencing problem within the
object graph when exposing objects through web methods under the WSI
Basic Profile 1.1 standard?

3. Consider a class (MyEntity) that has got some properties, say Prop1,
Prop2 and Prop3 all of boolean type. On the service side, consider
this:

MyEntity entity = new MyEntity();
entity.Prop1 = false;
entity.Prop2 = false;
entity.Prop3 = false;
return entity;

When the entity is marshaled to the client, the Prop2 is true, while
it's being set to false!!!! What the heck is going wrong with this?

TIA,
Mehdi
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,769
Messages
2,569,582
Members
45,057
Latest member
KetoBeezACVGummies

Latest Threads

Top