org.jboss.dna.connector.federation.contribution
Class ContributionStatistics

java.lang.Object
  extended by org.jboss.dna.connector.federation.contribution.ContributionStatistics

public class ContributionStatistics
extends Object

Simple utility class to record the distribution of contributions.

Author:
Randall Hauch

Nested Class Summary
static class ContributionStatistics.Data
           
static class ContributionStatistics.Stats
           
 
Constructor Summary
ContributionStatistics()
           
 
Method Summary
static Map<ContributionStatistics.Stats,AtomicLong> getData()
          Get a copy of the raw statistics data.
static List<ContributionStatistics.Data> getTop(int n)
          Get the N most populous combinations of properties and children counts.
 boolean isRecording()
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ContributionStatistics

public ContributionStatistics()
Method Detail

isRecording

public boolean isRecording()

getData

public static Map<ContributionStatistics.Stats,AtomicLong> getData()
Get a copy of the raw statistics data.

Returns:
a copy of the data; never null

getTop

public static List<ContributionStatistics.Data> getTop(int n)
Get the N most populous combinations of properties and children counts.

Parameters:
n - the maximum number of data objects to find and return in the raw data; must be positive
Returns:
the list of N (or fewer)


Copyright © 2008-Present JBoss a division of Red Hat. All Rights Reserved.