java调用sharepoint中的webservice 第2页
m_ServiceClient.engageModule("addressing");
Options options = m_ServiceClient.getOptions();
options.setTimeOutInMilliSeconds(2 * 60 * 1000);
options.setUseSeparateListener(false);
HttpTransportProperties.Authenticator basicauth = new HttpTransportProperties.Authenticator();
basicauth.setUsername(username);
basicauth.setPassword(pwd);
basicauth.setHost(hostname);
basicauth.setDomain(domaname);
List authPrefs = new ArrayList(1);
authPrefs.add(AuthPolicy.NTLM);
basicauth.setAuthSchemes(authPrefs);
options.setProperty(HTTPConstants.AUTHENTICATE, basicauth);
m_ServiceClient.setOptions(options);
m_Options=options;
// _serviceClient.getOptions().setProperty(org.apache.axis2.transport.http.HTTPConstants.CHUNKED,Boolean.FALSE);
}