Functions | |
Future< SSLSocket > | com.mobiledgex.matchingengine.AppConnectionManager.getTcpSslSocket (final AppClient.FindCloudletReply findCloudletReply, final AppPort appPort, final int portNum, final int timeoutMs) |
Future< Socket > | com.mobiledgex.matchingengine.AppConnectionManager.getTcpSocket (final AppClient.FindCloudletReply findCloudletReply, final AppPort appPort, final int portNum, final int timeoutMs) |
Future< DatagramSocket > | com.mobiledgex.matchingengine.AppConnectionManager.getUdpSocket (final AppClient.FindCloudletReply findCloudletReply, final AppPort appPort, final int portNum, final int timeoutMs) |
Future< OkHttpClient > | com.mobiledgex.matchingengine.AppConnectionManager.getHttpClient (final long timeoutMs) |
Future< OkHttpClient > com.mobiledgex.matchingengine.AppConnectionManager.getHttpClient | ( | final long | timeoutMs | ) |
Returns an HttpClient via OkHttpClient object, over a cellular network interface. Null is returned if a requested cellular network is not available or not allowed.
Convenience method. Get the network from NetworkManager, and set the SSLSocket factory for different communication protocols.
timeoutMs | (long): connect timeout in milliseconds. |
Future< Socket > com.mobiledgex.matchingengine.AppConnectionManager.getTcpSocket | ( | final AppClient.FindCloudletReply | findCloudletReply, |
final AppPort | appPort, | ||
final int | portNum, | ||
final int | timeoutMs | ||
) |
For early development only. This creates a connected Socket. Socket should be closed when the socket is no longer needed.
If a network goes down, sockets created using that network also gets killed.
findCloudletReply | (FindCloudletReply): A FindCloudletReply for the current location. |
appPort | (AppPort): This is the AppPort you want to connect to, based on the unmapped internal port number. |
portNum | (int): This is the internal port number of where the AppInst is actually made available in a particular cloudlet region. It may not match the appPort mapped public port number. If <= 0, it defaults to the public port. |
timeoutMs | (int): timeout in milliseconds. 0 for infinite. |
Future< SSLSocket > com.mobiledgex.matchingengine.AppConnectionManager.getTcpSslSocket | ( | final AppClient.FindCloudletReply | findCloudletReply, |
final AppPort | appPort, | ||
final int | portNum, | ||
final int | timeoutMs | ||
) |
Returns a Future with a TCP SSL Socket from a default SSL Socket Factory, created on a cellular data network interface, where available. The created socket is already connected. If the timeout is 0, it will not timeout. Socket should be closed when the socket is no longer needed. If a network goes down, sockets created using that network also gets killed.
findCloudletReply | (FindCloudletReply) |
appPort | (AppPort): This is the AppPort you want to connect to, based on the unmapped internal port number. |
portNum | (int): This is the internal port number of where the AppInst is actually made available in a particular cloudlet region. It may not match the appPort mapped public port number. If <= 0, it defaults to the first public port. |
timeoutMs | (int): timeout in milliseconds. 0 for infinite. |
Future< DatagramSocket > com.mobiledgex.matchingengine.AppConnectionManager.getUdpSocket | ( | final AppClient.FindCloudletReply | findCloudletReply, |
final AppPort | appPort, | ||
final int | portNum, | ||
final int | timeoutMs | ||
) |
Returns a UDP socket bound and connected to cellular interface. Socket should be closed when the socket is no longer needed.
If a network goes down, sockets created using that network also gets killed.
findCloudletReply | (FindCloudletReply): A FindCloudletReply for the current location. |
appPort | (AppPort): This is the AppPort you want to connect to, based on the unmapped internal port number. |
portNum | (int): This is the internal port number of where the AppInst is actually made available in a particular cloudlet region. It may not match the appPort mapped public port number. If <= 0, it defaults to the first public port. |
timeoutMs | (int): timeout in milliseconds. 0 for infinite. |