c# - WCF add attribute to soap body -
i need add attribute body element. how can this?
<soapenv:body wsu:id="body">
i'm using xmlserializerformat. code:
f[servicecontract(namespace = "http://tsutomfc")] [xmlserializerformat] public interface iservice { [xmlserializerformat] [operationcontract] responsetype sampletestsmev(); } [messagecontract] [xmlserializerformat] public class responsetype { [messageheader] public securitytype security = new securitytype(); [messageheader] public smevheader header = new smevheader(); [messagebodymember(namespace = "http://smev.gosuslugi.ru/rev120315")] public messagetype message = new messagetype(); [messagebodymember(namespace = "http://smev.gosuslugi.ru/rev120315")] public messagedatatype messagedata = new messagedatatype();
}
you can use idispatchmessageinspector enables custom modification of inbound , outbound messages.
Comments
Post a Comment