org.jdiameter.server.impl
Class StatisticImpl

java.lang.Object
  extended by org.jdiameter.server.impl.StatisticImpl
All Implemented Interfaces:
org.jdiameter.api.Statistic, org.jdiameter.api.Wrapper, IStatistic

public class StatisticImpl
extends java.lang.Object
implements IStatistic


Field Summary
protected  boolean enable
           
protected  java.util.concurrent.ConcurrentLinkedQueue<IStatisticRecord> records
           
 
Constructor Summary
StatisticImpl(java.lang.String name, java.lang.String desctiprion, org.jdiameter.api.StatisticRecord... rec)
           
 
Method Summary
 void appendCounter(java.util.Set<org.jdiameter.api.StatisticRecord> e)
          Merge statistic
 StatisticImpl appendCounter(org.jdiameter.api.StatisticRecord... rec)
           
 void enable(boolean e)
           
 java.lang.String getDescription()
           
 java.lang.String getName()
           
 java.util.Set<org.jdiameter.api.StatisticRecord> getRecords()
           
 boolean isEnable()
           
 boolean isWrapperFor(java.lang.Class<?> aClass)
           
 void reset()
           
 java.lang.String toString()
           
<T> T
unwrap(java.lang.Class<T> aClass)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

enable

protected boolean enable

records

protected java.util.concurrent.ConcurrentLinkedQueue<IStatisticRecord> records
Constructor Detail

StatisticImpl

public StatisticImpl(java.lang.String name,
                     java.lang.String desctiprion,
                     org.jdiameter.api.StatisticRecord... rec)
Method Detail

getName

public java.lang.String getName()
Specified by:
getName in interface org.jdiameter.api.Statistic

getDescription

public java.lang.String getDescription()
Specified by:
getDescription in interface org.jdiameter.api.Statistic

appendCounter

public StatisticImpl appendCounter(org.jdiameter.api.StatisticRecord... rec)

enable

public void enable(boolean e)
Specified by:
enable in interface org.jdiameter.api.Statistic

isEnable

public boolean isEnable()
Specified by:
isEnable in interface org.jdiameter.api.Statistic

reset

public void reset()
Specified by:
reset in interface org.jdiameter.api.Statistic

getRecords

public java.util.Set<org.jdiameter.api.StatisticRecord> getRecords()
Specified by:
getRecords in interface org.jdiameter.api.Statistic

appendCounter

public void appendCounter(java.util.Set<org.jdiameter.api.StatisticRecord> e)
Description copied from interface: IStatistic
Merge statistic

Specified by:
appendCounter in interface IStatistic
Parameters:
e - external statistic

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

isWrapperFor

public boolean isWrapperFor(java.lang.Class<?> aClass)
                     throws org.jdiameter.api.InternalException
Specified by:
isWrapperFor in interface org.jdiameter.api.Wrapper
Throws:
org.jdiameter.api.InternalException

unwrap

public <T> T unwrap(java.lang.Class<T> aClass)
         throws org.jdiameter.api.InternalException
Specified by:
unwrap in interface org.jdiameter.api.Wrapper
Throws:
org.jdiameter.api.InternalException


Copyright © 2008. All Rights Reserved.