STATSPROVIDER_ATTRIB);
Stats stats = (Stats) kernel.getAttribute(aname, STATS_ATTRIB);
if (statisticsProvider.booleanValue() == true && (stats != null)) {
String[] statisticNames = stats.getStatisticNames();
for (int i = 0; i < statisticNames.length; i++) {
Statistic statistic = stats.getStatistic(statisticNames[i]);
Collection<String[]> mbeanStat = new ArrayList<String[]>();
String name = statistic.getName();
mbeanStat.add(new String[] { "Name", name });
// String className = statistic.getClass().getName();
// mbeanStat.add(new String[] { "Type", className });
mbeanStat.add(new String[] { "Description", statistic.getDescription() });
mbeanStat.add(new String[] { "Unit", statistic.getUnit() });
Date startTime = new Date(statistic.getStartTime());
mbeanStat.add(new String[] { "Start Time", startTime.toString() });
Date lastSampleTime = new Date(statistic.getLastSampleTime());
mbeanStat.add(new String[] { "Last Sample Time", lastSampleTime.toString() });
if (statistic instanceof CountStatistic) {
CountStatistic cStat = (CountStatistic) statistic;
long count = cStat.getCount();