org.opennms.netmgt.dao.support
Class BottomNAttributeStatisticVisitor

java.lang.Object
  extended by org.opennms.netmgt.dao.support.BottomNAttributeStatisticVisitor
All Implemented Interfaces:
AttributeStatisticVisitor, AttributeStatisticVisitorWithResults, org.springframework.beans.factory.InitializingBean
Direct Known Subclasses:
TopNAttributeStatisticVisitor

public class BottomNAttributeStatisticVisitor
extends Object
implements AttributeStatisticVisitorWithResults, org.springframework.beans.factory.InitializingBean

BottomNAttributeStatisticVisitor class.

Version:
$Id: $
Author:
DJ Gregor

Nested Class Summary
 class BottomNAttributeStatisticVisitor.AttributeStatisticComparator
           
 class BottomNAttributeStatisticVisitor.DoubleComparator
           
 
Field Summary
protected  Comparator<Double> m_comparator
           
 
Constructor Summary
BottomNAttributeStatisticVisitor()
          Constructor for BottomNAttributeStatisticVisitor.
 
Method Summary
 void afterPropertiesSet()
          afterPropertiesSet
 Comparator<Double> getComparator()
          getComparator
 Integer getCount()
          getCount
 SortedSet<AttributeStatistic> getResults()
          getResults
 void setComparator(Comparator<Double> comparator)
          setComparator
 void setCount(Integer count)
          setCount
 void visit(OnmsAttribute attribute, double statistic)
          visit
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

m_comparator

protected Comparator<Double> m_comparator
Constructor Detail

BottomNAttributeStatisticVisitor

public BottomNAttributeStatisticVisitor()

Constructor for BottomNAttributeStatisticVisitor.

Method Detail

visit

public void visit(OnmsAttribute attribute,
                  double statistic)

visit

Specified by:
visit in interface AttributeStatisticVisitor
Parameters:
attribute - a OnmsAttribute object.
statistic - a double.

afterPropertiesSet

public void afterPropertiesSet()

afterPropertiesSet

Specified by:
afterPropertiesSet in interface AttributeStatisticVisitorWithResults
Specified by:
afterPropertiesSet in interface org.springframework.beans.factory.InitializingBean
See Also:
InitializingBean.afterPropertiesSet()

getCount

public Integer getCount()

getCount

Specified by:
getCount in interface AttributeStatisticVisitorWithResults
Returns:
a Integer object.

setCount

public void setCount(Integer count)

setCount

Specified by:
setCount in interface AttributeStatisticVisitorWithResults
Parameters:
count - a Integer object.

getResults

public SortedSet<AttributeStatistic> getResults()

getResults

Specified by:
getResults in interface AttributeStatisticVisitorWithResults
Returns:
top attribute statistics (up to getCount() number)

getComparator

public Comparator<Double> getComparator()

getComparator

Returns:
a Comparator object.

setComparator

public void setComparator(Comparator<Double> comparator)

setComparator

Parameters:
comparator - a Comparator object.


Copyright © 2011. All Rights Reserved.