Class ConnectionPool<T extends Connector>
- java.lang.Object
-
- org.restlet.engine.util.Pool<Connection<T>>
-
- org.restlet.ext.nio.internal.connection.ConnectionPool<T>
-
@Deprecated public class ConnectionPool<T extends Connector> extends Pool<Connection<T>>
Deprecated.Will be removed to favor lower-level network extensions allowing more control at the Restlet API level.A connection pool to prevent to recreation of heavy byte buffers.
-
-
Field Summary
Fields Modifier and Type Field Description private ConnectionHelper<T>helperDeprecated.The parent helper.
-
Constructor Summary
Constructors Constructor Description ConnectionPool(ConnectionHelper<T> helper, int initialSize)Deprecated.Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description protected voidclear(Connection<T> connection)Deprecated.Clears the given object when it is checked in the pool.protected Connection<T>createObject()Deprecated.Creates a new reusable object.
-
-
-
Field Detail
-
helper
private ConnectionHelper<T extends Connector> helper
Deprecated.The parent helper.
-
-
Constructor Detail
-
ConnectionPool
public ConnectionPool(ConnectionHelper<T> helper, int initialSize)
Deprecated.Constructor.- Parameters:
helper- The parent helper.initialSize- The initial pool size.
-
-
Method Detail
-
clear
protected void clear(Connection<T> connection)
Deprecated.Description copied from class:PoolClears the given object when it is checked in the pool. Does nothing by default.- Overrides:
clearin classPool<Connection<T extends Connector>>- Parameters:
connection- The object to clear.
-
createObject
protected Connection<T> createObject()
Deprecated.Description copied from class:PoolCreates a new reusable object.- Specified by:
createObjectin classPool<Connection<T extends Connector>>- Returns:
- A new reusable object.
-
-