|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.apache.http.impl.conn.tsccm.RouteSpecificPool
AbstractConnPool
@Deprecated public class RouteSpecificPool
A connection sub-pool for a specific route, used by ConnPoolByRoute
.
The methods in this class are unsynchronized. It is expected that the
containing pool takes care of synchronization.
Field Summary | |
---|---|
protected ConnPerRoute |
connPerRoute
Deprecated. Connections per route |
protected LinkedList<BasicPoolEntry> |
freeEntries
Deprecated. The list of free entries. |
protected int |
maxEntries
Deprecated. |
protected int |
numEntries
Deprecated. The number of created entries. |
protected HttpRoute |
route
Deprecated. The route this pool is for. |
protected Queue<WaitingThread> |
waitingThreads
Deprecated. The list of threads waiting for this pool. |
Constructor Summary | |
---|---|
RouteSpecificPool(HttpRoute route,
ConnPerRoute connPerRoute)
Deprecated. Creates a new route-specific pool. |
|
RouteSpecificPool(HttpRoute route,
int maxEntries)
Deprecated. (4.1) use RouteSpecificPool(HttpRoute, ConnPerRoute) |
Method Summary | |
---|---|
BasicPoolEntry |
allocEntry(Object state)
Deprecated. Obtains a free entry from this pool, if one is available. |
void |
createdEntry(BasicPoolEntry entry)
Deprecated. Indicates creation of an entry for this pool. |
boolean |
deleteEntry(BasicPoolEntry entry)
Deprecated. Deletes an entry from this pool. |
void |
dropEntry()
Deprecated. Forgets about an entry from this pool. |
void |
freeEntry(BasicPoolEntry entry)
Deprecated. Returns an allocated entry to this pool. |
int |
getCapacity()
Deprecated. Return remaining capacity of this pool |
int |
getEntryCount()
Deprecated. Obtains the number of entries. |
int |
getMaxEntries()
Deprecated. Obtains the maximum number of entries allowed for this pool. |
HttpRoute |
getRoute()
Deprecated. Obtains the route for which this pool is specific. |
boolean |
hasThread()
Deprecated. Checks whether there is a waiting thread in this pool. |
boolean |
isUnused()
Deprecated. Indicates whether this pool is unused. |
WaitingThread |
nextThread()
Deprecated. Returns the next thread in the queue. |
void |
queueThread(WaitingThread wt)
Deprecated. Adds a waiting thread. |
void |
removeThread(WaitingThread wt)
Deprecated. Removes a waiting thread, if it is queued. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected final HttpRoute route
protected final int maxEntries
protected final ConnPerRoute connPerRoute
protected final LinkedList<BasicPoolEntry> freeEntries
protected final Queue<WaitingThread> waitingThreads
protected int numEntries
Constructor Detail |
---|
@Deprecated public RouteSpecificPool(HttpRoute route, int maxEntries)
RouteSpecificPool(HttpRoute, ConnPerRoute)
public RouteSpecificPool(HttpRoute route, ConnPerRoute connPerRoute)
route
- the route for which to poolconnPerRoute
- the connections per route configurationMethod Detail |
---|
public final HttpRoute getRoute()
public final int getMaxEntries()
public boolean isUnused()
true
if this pool is unused,
false
otherwisepublic int getCapacity()
public final int getEntryCount()
public BasicPoolEntry allocEntry(Object state)
null
if there is nonepublic void freeEntry(BasicPoolEntry entry)
entry
- the entry obtained from allocEntry
or presented to createdEntry
public void createdEntry(BasicPoolEntry entry)
freeEntry
.
entry
- the entry that was created for this poolpublic boolean deleteEntry(BasicPoolEntry entry)
entry
- the entry to delete from this pool
true
if the entry was found and deleted, or
false
if the entry was not foundpublic void dropEntry()
allocated
from this pool has been lost and will not be returned.
public void queueThread(WaitingThread wt)
wt
- the waiting threadpublic boolean hasThread()
true
if there is a waiting thread,
false
otherwisepublic WaitingThread nextThread()
null
if there is nonepublic void removeThread(WaitingThread wt)
wt
- the waiting thread
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |