Package com.squareup.okhttp
Class ConfigAwareConnectionPool
- java.lang.Object
-
- com.squareup.okhttp.ConfigAwareConnectionPool
-
public class ConfigAwareConnectionPool extends Object
A provider of the shared AndroidConnectionPool. This class is aware of network configuration change events: When the network configuration changes the pool object is discarded and a later calls toget()will return a new pool.
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedConfigAwareConnectionPool(NetworkEventDispatcher networkEventDispatcher)Visible for testing.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description ConnectionPoolget()Returns the currentConnectionPoolto use.static ConfigAwareConnectionPoolgetInstance()
-
-
-
Constructor Detail
-
ConfigAwareConnectionPool
protected ConfigAwareConnectionPool(NetworkEventDispatcher networkEventDispatcher)
Visible for testing. UsegetInstance()
-
-
Method Detail
-
getInstance
public static ConfigAwareConnectionPool getInstance()
-
get
public ConnectionPool get()
Returns the currentConnectionPoolto use.
-
-