KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > smartlib > pool > core > PoolMonitor


1 /*
2  * @(#) ConnectionMonitor 1.0 02/08/01
3  */

4
5 package org.smartlib.pool.core;
6
7 /**
8  * This interface defines the behavior of the class used to monitor
9  * a Pool. This interface defines the methods which can
10  * be used to monitor the runtime status of the pools.
11  * @author Sachin Shekar Shetty
12  * @version 1.0, 02/08/01
13  *
14  */

15
16 import java.util.*;
17
18 public interface PoolMonitor {
19
20     /**
21      * @return Current size of the pool.
22      */

23     public int getCurrentPoolSize();
24
25     /**
26      * @return Number of free connections in the pool
27      */

28     public int getNoOfFreeConnections();
29
30     /**
31      * @return Vector containing the connections that are currently in use.
32      */

33     public Vector getConnectionsInUse();
34
35     /**
36      * @return Instance of ConfigMonitor to examine the
37      * configuration of the pool.
38      */

39     public ConfigMonitor getConfigMonitor();
40
41     /**
42      * This method returns the name of the pool
43      */

44     public String JavaDoc getName();
45
46 }
47
Popular Tags