/** Creates a new instance of FactoryDisabled */ public FactoryDisabled(MonitorFactoryInterface factoryEnabled) { this.factoryEnabled=factoryEnabled; nullMon=new MonitorImp(); nullMon.disable(); }
private List getThisRowData(List rowData) { rowData.add(new Double(getHits())); rowData.add(new Double(getAvg())); rowData.add(new Double(getTotal())); rowData.add(new Double(getStdDev())); rowData.add(new Double(getLastValue())); rowData.add(new Double(getMin())); rowData.add(new Double(getMax())); rowData.add(new Double(getActive())); rowData.add(new Double(getAvgActive())); rowData.add(new Double(getMaxActive())); rowData.add(getFirstAccess()); rowData.add(getLastAccess()); rowData.add(bool(isEnabled())); rowData.add(bool(isPrimary())); rowData.add(bool(hasListeners())); return rowData; }
private Object[] getBasicRowData(MonitorImp mon) { List row=new ArrayList(); mon.getBasicRowData(row); return row.toArray(); }
private MonitorImp createMon(MonKey key, boolean isPrimary, boolean isTimeMonitor) { ActivityStats activityStats=new ActivityStats(new Counter(), primaryActive, allActive); // get default range for this type and assign it to the monitor RangeImp range=rangeFactory.getRangeDefault(key.getRangeKey(), activityStats); MonitorImp mon=new MonitorImp(key, range, activityStats, isTimeMonitor); // activity tracking is off by default. if (isTotalKeySizeTrackingEnabled()) { incrementKeySize(key.getSize()); } if (activityTracking) { mon.setActivityTracking(activityTracking); } mon.setPrimary(isPrimary); return mon; }
private MonitorImp createMon(MonKey key, boolean isPrimary, boolean isTimeMonitor) { ActivityStats activityStats=new ActivityStats(new Counter(), primaryActive, allActive); // get default range for this type and assign it to the monitor RangeImp range=rangeFactory.getRangeDefault(key.getRangeKey(), activityStats); MonitorImp mon=new MonitorImp(key, range, activityStats, isTimeMonitor); mon.setPrimary(isPrimary); return mon; }
@Override public List getHeader(List header) { super.getHeader(header); header.add(monData.name+"AvgActive"); header.add(monData.name+"AvgPrimaryActive"); header.add(monData.name+"AvgGlobalActive"); return header; }
/** Return the header with basic data and one column for each range. Note this only will work with ranges of the same type */ public String[] getDisplayHeader() { List header=new ArrayList(); if (hasData()) { // being as all monitors in the composite should have the same range // getting the first one should suffice to get the header getFirstMon().getDisplayHeader(header); return (String[]) header.toArray(new String[0]); } else return null; }
/** Return the header that applies to all monitors. It does not include range column headers. ** It will contain label, hits, total, avg, min, max and active among other columns **/ public String[] getBasicHeader() { List header=new ArrayList(); if (hasData()) { // being as all monitors in the composite should have the same range // getting the first one should suffice to get the header getFirstMon().getBasicHeader(header); return (String[]) header.toArray(new String[0]); } else return null; }
public List getHeader(List header) { super.getHeader(header); header.add(monData.name+"AvgActive"); header.add(monData.name+"AvgPrimaryActive"); header.add(monData.name+"AvgGlobalActive"); return header; }
/** Return the header with basic data and one column for each range. Note this only will work with ranges of the same type */ public String[] getDisplayHeader() { List header=new ArrayList(); if (hasData()) { // being as all monitors in the composite should have the same range // getting the first one should suffice to get the header getFirstMon().getDisplayHeader(header); return (String[]) header.toArray(new String[0]); } else return null; }
/** Return the header that applies to all monitors. It does not include range column headers. ** It will contain label, hits, total, avg, min, max and active among other columns **/ public String[] getBasicHeader() { List header=new ArrayList(); if (hasData()) { // being as all monitors in the composite should have the same range // getting the first one should suffice to get the header getFirstMon().getBasicHeader(header); return (String[]) header.toArray(new String[0]); } else return null; }
private List getThisRowData(List rowData) { rowData.add(new Double(getHits())); rowData.add(new Double(getAvg())); rowData.add(new Double(getTotal())); rowData.add(new Double(getStdDev())); rowData.add(new Double(getLastValue())); rowData.add(new Double(getMin())); rowData.add(new Double(getMax())); rowData.add(new Double(getActive())); rowData.add(new Double(getAvgActive())); rowData.add(new Double(getMaxActive())); rowData.add(getFirstAccess()); rowData.add(getLastAccess()); rowData.add(new Boolean(isEnabled())); rowData.add(new Boolean(isPrimary())); rowData.add(new Boolean(hasListeners())); return rowData; }
/** Return the header with basic data and columns for each field within the range. note getHeader only works if the range of all monitors in the composite are the same. **/ public String[] getHeader() { List header=new ArrayList(); if (hasData()) { // being as all monitors in the composite should have the same range // getting the first one should suffice to get the header getFirstMon().getHeader(header); return (String[]) header.toArray(new String[0]); } else return null; }
public Monitor getMonitor() { return new MonitorImp(new MonKeyImp("defaultMon","defaultMon"), null, new ActivityStats(), false); }
private Object[] getBasicRowData(MonitorImp mon) { List row=new ArrayList(); mon.getBasicRowData(row); return row.toArray(); }
/** Return the header with basic data and columns for each field within the range. note getHeader only works if the range of all monitors in the composite are the same. **/ public String[] getHeader() { List header=new ArrayList(); if (hasData()) { // being as all monitors in the composite should have the same range // getting the first one should suffice to get the header getFirstMon().getHeader(header); return (String[]) header.toArray(new String[0]); } else return null; }
public Monitor getMonitor() { return new MonitorImp(new MonKeyImp("defaultMon","defaultMon"), null, new ActivityStats(), false); }