org.idoox.webservice.client
Class WebServiceHelper

java.lang.Object
  extended byorg.idoox.webservice.client.WebServiceHelper

public class WebServiceHelper
extends java.lang.Object

This class enables access to the WebService service methods of a stub.

Since:
1.0
Component:
Core

Constructor Summary
WebServiceHelper()
          Deprecated.  
 
Method Summary
static CallContext getCallContext(java.lang.Object stub)
          Deprecated. Use ServiceClient.
static Credentials[] getCredentials(java.lang.Object stub)
          Deprecated.  
static java.lang.String getSecurityProvider(java.lang.Object stub)
          Deprecated. since WASP4.5
static java.util.Map getStubContext(java.lang.Object stub)
          Deprecated. Use ServiceClient.
static WebService getWebService(java.lang.Object stub)
          Deprecated. Use Current instead of WebService
static int select(AsyncReceipt[] receipts, long timeout)
          Deprecated. use AsyncConversation
static int select(java.util.List receipts, long timeout)
          Deprecated. use AsyncConversation
static void setCredentials(java.lang.Object stub, Credentials[] creds)
          Deprecated. since WASP4.5
static void setSecurityProvider(java.lang.Object stub, java.lang.String providerName)
          Deprecated. since WASP4.5
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

WebServiceHelper

public WebServiceHelper()
Deprecated. 
Method Detail

getWebService

public static WebService getWebService(java.lang.Object stub)
Deprecated. Use Current instead of WebService

Returns WebService interface instance for given web service stub.

Parameters:
stub - web service stub for which the WebService interface has to be returned
Returns:
WebService interface instance for given web service stub

getCallContext

public static CallContext getCallContext(java.lang.Object stub)
Deprecated. Use ServiceClient.

Returns call context associated with given web service stub

Parameters:
stub - web service stub for which the call context should be returned
Returns:
CallContext instance associated with given web service stub.

getStubContext

public static java.util.Map getStubContext(java.lang.Object stub)
Deprecated. Use ServiceClient.

Returns stub context associated with given web service stub.

Parameters:
stub - web service stub for which the stub context should be returned
Returns:
Map instance representing the stub context associated with given web service stub

getCredentials

public static Credentials[] getCredentials(java.lang.Object stub)
Deprecated.  

Deprecated, use the WaspSecurity.getInstance().getCredentials() method instead.

Parameters:
stub - Web Service stub to be used
Returns:
array of Credentials for given stub

setCredentials

public static void setCredentials(java.lang.Object stub,
                                  Credentials[] creds)
Deprecated. since WASP4.5

Deprecated, use the WaspSecurity.getInstance().setCredentials(Object,Credentials[] method instead.

Parameters:
stub - Web Service stub to be used
creds - array of Credentials to be set for given stub

setSecurityProvider

public static void setSecurityProvider(java.lang.Object stub,
                                       java.lang.String providerName)
                                throws java.security.NoSuchProviderException
Deprecated. since WASP4.5

Deprecated, use the WaspSecurity.setInitiatingProvider(Object,String) method instead.

Parameters:
stub - Web Service stub to be set the security provider on
providerName - name of the provider to be activated on given stub, can be null to deactivate authentication security
Throws:
java.security.NoSuchProviderException

getSecurityProvider

public static java.lang.String getSecurityProvider(java.lang.Object stub)
Deprecated. since WASP4.5

Deprecated, use the WaspSecurity.getInitiatingProvider(Object) method instead.

Parameters:
stub - Web Service stub to be used
Returns:
name of the security provider for given stub

select

public static int select(AsyncReceipt[] receipts,
                         long timeout)
                  throws java.lang.InterruptedException
Deprecated. use AsyncConversation

This method implements waiting on a set of receipts, together with a timeout. The method returns after one or more receipts in the provided array are finished (will return true from isFinished()) or after the timeout in milliseconds. In case any of the provided receipts is already finished, the method will return immediately.

Parameters:
receipts - an array of receipts for which the call should wait
timeout - the timeout in milliseconds, can be zero which signifies no timeout.
Returns:
number of receipts in the array that are finished.
Throws:
java.lang.InterruptedException - when the waiting is interrupted

select

public static int select(java.util.List receipts,
                         long timeout)
                  throws java.lang.InterruptedException
Deprecated. use AsyncConversation

This method implements waiting on a set of receipts, together with a timeout. The method returns after one or more receipts in the provided list are finished (will return true from isFinished()) or after the timeout in milliseconds. In case any of the provided receipts is already finished, the method will return immediately.

Parameters:
receipts - a list of receipts for which the call should wait
timeout - the timeout in milliseconds, can be zero which signifies no timeout.
Returns:
number of receipts in the list that are finished.
Throws:
java.lang.InterruptedException - when the waiting is interrupted