1 7 package org.ejtools.management.browser.ui.statistics; 8 9 import javax.management.j2ee.statistics.BoundaryStatistic ; 10 import javax.management.j2ee.statistics.Statistic ; 11 import javax.swing.JLabel ; 12 13 17 public class BoundaryStatisticCustomizer extends StatisticCustomizer 18 { 19 20 protected JLabel lblLowerBound = null; 21 22 protected JLabel lblUpperBound = null; 23 24 25 30 public BoundaryStatisticCustomizer(Statistic statistic) 31 { 32 super(statistic); 33 34 this.lblUpperBound = new JLabel (""); 35 this.addGraphItem( 36 resources.getString("customizer.tab.statistics.text.lower.bound"), 37 resources.getString("customizer.tab.statistics.tooltip.lower.bound"), 38 "UpperBound", 39 this.lblUpperBound); 40 this.lblLowerBound = new JLabel (""); 41 this.addGraphItem( 42 resources.getString("customizer.tab.statistics.text.upper.bound"), 43 resources.getString("customizer.tab.statistics.tooltip.upper.bound"), 44 "LowerBound", 45 this.lblLowerBound); 46 } 47 48 49 50 public void refresh() 51 { 52 if (this.statistic != null) 53 { 54 long value; 55 BoundaryStatistic bs = (BoundaryStatistic ) this.statistic; 56 57 value = bs.getUpperBound(); 58 this.lblUpperBound.setText("" + value); 59 value = bs.getLowerBound(); 60 this.lblLowerBound.setText("" + value); 61 62 super.refresh(); 63 } 64 } 65 } 66 | Popular Tags |