SilverStream
Application Server 3.5

com.sssw.rts.adminapi
Interface AgiAdmStatSet


public interface AgiAdmStatSet

This is the administrative interface to a set of SilverStream statistics ("counters"), containing performance-related data. An application can create a counter set as an efficient technique for retrieving a batch of (possibly unrelated) counter values. A statistics set is mutable -- individual statistics may be added to or deleted from the set as desired.


Field Summary
static long STAT_UNAVAILABLE
          This value is returned in getValues for statistics which are not available for a particular element.
 
Method Summary
 void addStat(AgoAdmStatInfo stat)
          Add a statistic to this set.
 AgoAdmStatInfo[] getStats()
          Get information about all statistics maintained by this instance.
 long[] getValues()
          Fetch the values of all the counters in the set.
 void removeStat(AgoAdmStatInfo stat)
          Remove a statistic from the set.
 void setStats(AgoAdmStatInfo[] stats)
          Set a group of statistics
 void toFile(File file)
          Write statistics set to a file.
 void toStream(OutputStream out)
          Write statistics set to an output stream.
 

Field Detail

STAT_UNAVAILABLE

public static final long STAT_UNAVAILABLE
This value is returned in getValues for statistics which are not available for a particular element.

Usage: getValues

Method Detail

addStat

public void addStat(AgoAdmStatInfo stat)
Add a statistic to this set. It's not an error to add a specified counter twice -- it will simply be retrieved twice.
Usage:
Once the getValues call is issued, the statistic set is committed to the server, and no more addStat calls are allowed.

removeStat

public void removeStat(AgoAdmStatInfo stat)
Remove a statistic from the set. If the counter is present in the set more than once, the first counter instance in the set will be removed.
Usage:
Once the getValues call is issued, the statistic set is committed to the server, and no more removeStat calls are allowed.

setStats

public void setStats(AgoAdmStatInfo[] stats)
Set a group of statistics
Parameters:
stats - an array of AgoAdmStatInfo's
Usage:
Once the getValues call is issued, the statistic set is committed to the server, and no more setStats calls are allowed.

getStats

public AgoAdmStatInfo[] getStats()
Get information about all statistics maintained by this instance.
Returns:
an array of AgoAdmStatInfos

toStream

public void toStream(OutputStream out)
              throws AgoUnrecoverableSystemException,
                     IOException
Write statistics set to an output stream.

toFile

public void toFile(File file)
            throws AgoUnrecoverableSystemException,
                   IOException
Write statistics set to a file.

getValues

public long[] getValues()
                 throws AgoUnrecoverableSystemException,
                        AgoSecurityException
Fetch the values of all the counters in the set. The counters are returned as an array, in the order the counters were added to the set.

SilverStream
Application Server 3.5