0

考虑以下:

public MyCustomHeader MyHeader;

public New()
{
    //MyHeader is NOT instantiated
}


[SoapHeader("MyHeader")]
[WebMethod()]
public bool MyFunction()
{
    //MyHeader is instantiated, but when was it instantiated?
}
4

2 回答 2

0

在您的示例中,它将在方法执行之前被实例化MyFunction。因为需要 Header 才能执行 MyFunction 的操作。

于 2009-04-22T20:26:01.003 回答
0
how to convert this part and attach to XML in android?
POST /SharingpointCheckBarcode.asmx HTTP/1.1
Host: awc.test.trin-it.nl
Content-Type: text/xml; charset=utf-8
Content-Length: length
SOAPAction: "http://tempuri.org/checkBarcode"
于 2012-08-02T10:50:19.923 回答