10-16-2006 12:29 PM
AuthenticationUtils.startSession(login,password);and RepositoryServiceSoapBindingStub repositoryService = WebServiceFactory.getRepositoryService(); 10-17-2006 10:05 AM
Application sets parameters to insert insee http://ws.apache.org/wss4j/package.html for more information.
Sometimes it is not feasable or not possible to determine parameters and their values during deployment. In this case the application can set paramters during runtime. The WSS4J Axis handlers use the Axis setProperty method to support this feature.
The following code snippet shows an example how to use the dynamic setting of parameters and their values:
…
Service service = new Service();
Call call = (Call) service.createCall();
…
call.setProperty(UsernameToken.PASSWORD_TYPE, WSConstants.PASSWORD_TEXT);
call.setProperty(WSHandlerConstants.USER, "werner");
…
Use this way if your application dynamically creates a call object. If your application uses stubs generated by Axis' WSDL2Java tool, the application uses the following functions:
…
PingServiceLocator service = new PingServiceLocator();
…
PingPort port = (PingPort) service.getPing1();
port._setProperty(UsernameToken.PASSWORD_TYPE, WSConstants.PASSWORD_TEXT);
port._setProperty(WSHandlerConstants.USER, "werner");
…
Please note that _setProperty is a Axis specific call.
It is also possible to set the user's name and the according password via the call function, for example:
…
call.setUsername("name");
call.setPassword("WSS4Java");
…
RepositoryServiceSoapBindingStub repositoryService = WebServiceFactory.getRepositoryService();
repositoryService._getCall() …11-07-2006 05:50 AM
Tags
Find what you came for
We want to make your experience in Hyland Connect as valuable as possible, so we put together some helpful links.