/** * This method returns semi-structured data on this queue. * <p> * @see org.apache.commons.jcs.engine.behavior.ICacheEventQueue#getStatistics() * @return information on the status and history of the queue */ @Override public IStats getStatistics() { IStats stats = new Stats(); stats.setTypeName( "Cache Event Queue" ); ArrayList<IStatElement<?>> elems = new ArrayList<IStatElement<?>>(); elems.add(new StatElement<Boolean>( "Working", Boolean.valueOf(this.isWorking()) ) ); elems.add(new StatElement<Boolean>( "Alive", Boolean.valueOf(this.isAlive()) ) ); elems.add(new StatElement<Boolean>( "Empty", Boolean.valueOf(this.isEmpty()) ) ); elems.add(new StatElement<Integer>( "Size", Integer.valueOf(this.size()) ) ); stats.setStatElements( elems ); return stats; }