org.ksoap2.transport
Interface ServiceConnection

All Known Implementing Classes:
ServiceConnectionMidp, ServiceConnectionSE

public interface ServiceConnection

Interface to allow the abstraction of the raw transport information


Method Summary
 void connect()
          Make an outgoing connection.
 void disconnect()
          Disconnect from the outgoing connection
 java.io.InputStream getErrorStream()
           
 java.io.InputStream openInputStream()
          Opens and returns the inputstream from which to parse the result of the soap call.
 java.io.OutputStream openOutputStream()
          Open and return the outputStream to the endpoint.
 void setRequestMethod(java.lang.String requestMethodType)
          Sets how to make the requests.
 void setRequestProperty(java.lang.String propertyName, java.lang.String value)
          Set properties on the outgoing connection.
 

Method Detail

connect

void connect()
             throws java.io.IOException
Make an outgoing connection.

Throws:
java.io.IOException

disconnect

void disconnect()
                throws java.io.IOException
Disconnect from the outgoing connection

Throws:
java.io.IOException

setRequestProperty

void setRequestProperty(java.lang.String propertyName,
                        java.lang.String value)
                        throws java.io.IOException
Set properties on the outgoing connection.

Parameters:
propertyName - the name of the property to set. For HTTP connections these are the request properties in the HTTP Header.
value - the string to set the property header to.
Throws:
java.io.IOException

setRequestMethod

void setRequestMethod(java.lang.String requestMethodType)
                      throws java.io.IOException
Sets how to make the requests. For HTTP this is typically POST or GET.

Parameters:
requestMethodType - the type of request method to make the soap call with.
Throws:
java.io.IOException

openOutputStream

java.io.OutputStream openOutputStream()
                                      throws java.io.IOException
Open and return the outputStream to the endpoint.

Returns:
the output stream to write the soap message to.
Throws:
java.io.IOException

openInputStream

java.io.InputStream openInputStream()
                                    throws java.io.IOException
Opens and returns the inputstream from which to parse the result of the soap call.

Returns:
the inputstream containing the xml to parse the result from the call from.
Throws:
java.io.IOException

getErrorStream

java.io.InputStream getErrorStream()
Returns:
the error stream for the call.