|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.waveset.util.HttpsUtil
Utility to provide Https connection functionality regardless of Java version.
Nested Class Summary | |
static class |
HttpsUtil.HttpsConnectionException
|
static class |
HttpsUtil.HttpsUtilException
Allows differentiating between exceptions passed up from implementation code, and exceptions detected by the HttpsUtil itself. |
static interface |
HttpsUtil.InputStreamHandler
Enables client code to process data in the response from an HTTPS server after posting a message to it. |
Field Summary | |
protected static Trace |
_trace
|
static java.lang.String |
CLASS
|
static java.lang.String |
IMPL_PROPERTY
|
protected javax.net.SocketFactory |
mSslSocketFactory
SocketFactory instance used by the JSSE implementations. |
Constructor Summary | |
protected |
HttpsUtil()
|
Method Summary | |
static HttpsUtil |
createHttpsUtil(java.lang.String requestedImplementation,
java.lang.String certificatePath,
java.lang.String passPhrase,
java.lang.String certificateType,
java.lang.String rootCAPath)
|
protected java.net.URL |
createURL(java.lang.String requestString)
Create the server URL based on request String. |
protected abstract java.io.InputStream |
getInputStream(java.net.URL url,
java.lang.String message)
Given the (https) url for the server, send the specified message and return an input stream for the response. |
protected void |
initialize(java.lang.String certificatePath,
java.lang.String passPhrase,
java.lang.String certType,
java.lang.String rootCAPath)
Initialized the internal state needed to make a connection. |
java.lang.Object |
post(java.lang.String host,
java.lang.String port,
java.lang.String path,
java.lang.String message,
HttpsUtil.InputStreamHandler handler)
|
protected static void |
writeMessageToStream(java.io.OutputStream os,
java.lang.String message)
Output the specified message to the stream. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static final java.lang.String CLASS
public static final java.lang.String IMPL_PROPERTY
protected static Trace _trace
protected javax.net.SocketFactory mSslSocketFactory
Constructor Detail |
protected HttpsUtil()
Method Detail |
public static HttpsUtil createHttpsUtil(java.lang.String requestedImplementation, java.lang.String certificatePath, java.lang.String passPhrase, java.lang.String certificateType, java.lang.String rootCAPath) throws java.lang.Exception
java.lang.Exception
protected abstract java.io.InputStream getInputStream(java.net.URL url, java.lang.String message) throws java.lang.Exception
url
- Server urlmessage
- Message to send to server.
java.lang.Exception
public java.lang.Object post(java.lang.String host, java.lang.String port, java.lang.String path, java.lang.String message, HttpsUtil.InputStreamHandler handler) throws java.lang.Exception
java.lang.Exception
protected void initialize(java.lang.String certificatePath, java.lang.String passPhrase, java.lang.String certType, java.lang.String rootCAPath) throws java.security.NoSuchAlgorithmException, java.security.KeyManagementException, java.io.IOException, java.security.cert.CertificateException, java.security.UnrecoverableKeyException, java.security.KeyStoreException
java.security.NoSuchAlgorithmException
java.security.KeyManagementException
java.io.IOException
java.security.cert.CertificateException
java.security.UnrecoverableKeyException
java.security.KeyStoreException
protected java.net.URL createURL(java.lang.String requestString) throws java.net.MalformedURLException
java.net.MalformedURLException
protected static void writeMessageToStream(java.io.OutputStream os, java.lang.String message) throws java.io.IOException
os
- OutputStream to receive the message, closed on completion.message
- String to write to ActivCard server.
java.io.IOException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |