org.trippi.impl.base
Interface TriplestoreSessionPool

All Known Implementing Classes:
ConfigurableSessionPool, SingleSessionPool

public interface TriplestoreSessionPool

A pool of triplestore sessions.


Method Summary
 void close()
          Close all sessions.
 TriplestoreSession get()
          Get a connection from the pool.
 int getFreeCount()
          Get the number of sessions not currently in use.
 int getInUseCount()
          Get the number of sessions currently in use.
 java.lang.String[] listTripleLanguages()
           
 java.lang.String[] listTupleLanguages()
           
 void release(TriplestoreSession session)
          Release a connection back to the pool.
 

Method Detail

get

TriplestoreSession get()
                       throws TrippiException
Get a connection from the pool.

Returns:
a session, or null if none are available and growth isnt allowed.
Throws:
TrippiException - if there were no spare sessions and an attempt to create one on-demand failed.

release

void release(TriplestoreSession session)
Release a connection back to the pool.


listTupleLanguages

java.lang.String[] listTupleLanguages()

listTripleLanguages

java.lang.String[] listTripleLanguages()

getInUseCount

int getInUseCount()
Get the number of sessions currently in use.


getFreeCount

int getFreeCount()
Get the number of sessions not currently in use.


close

void close()
           throws TrippiException
Close all sessions.

Throws:
TrippiException