protected void setupCacheSamplesPanel() { cacheSamplesPanel = new CacheSamplesPanel(); // only add scroll bars in per-region mode if (globalMode) { add(cacheSamplesPanel); } else { cacheSamplesScrollPane = new JScrollPane(cacheSamplesPanel); cacheSamplesScrollPane.setHorizontalScrollBarPolicy(ScrollPaneConstants.HORIZONTAL_SCROLLBAR_NEVER); cacheSamplesScrollPane.setVerticalScrollBarPolicy(ScrollPaneConstants.VERTICAL_SCROLLBAR_AS_NEEDED); cacheSamplesScrollPane.getVerticalScrollBar().setUnitIncrement(16); add(cacheSamplesScrollPane); } repaint(); }
protected void init() { cacheSamplesPanel.start(); addPolledAttributeListener(); }
protected AggregateVuMeterPanel(final ApplicationContext appContext, final boolean globalMode) { this.appContext = appContext; this.globalMode = globalMode; this.repaintCacheSamplesPanel = new Runnable() { public void run() { if (cacheSamplesPanel != null) { cacheSamplesPanel.repaint(); } } }; setLayout(new BorderLayout()); setup(); }
private XContainer createMainPanel(boolean globalMode) { XContainer panel = new XContainer(new BorderLayout()); panel.add(vuMeterPanel = new AggregateVuMeterPanel(appContext, globalMode), BorderLayout.CENTER); return panel; }
private void init() { if (!tornDown.get()) { vuMeterPanel.setup(appContext, clusterModel, persistenceUnit); } }
public void setup(ApplicationContext appContext, IClusterModel clusterModel, String persistenceUnit) { this.clusterModel = clusterModel; this.persistenceUnit = persistenceUnit; try { statsBeanObjectName = HibernateStatsUtils.getHibernateStatsBeanName(persistenceUnit); } catch (Exception e) { throw new RuntimeException(e); } clusterModel.addPropertyChangeListener(clusterListener = new ClusterListener(clusterModel)); if (clusterModel.isReady()) { init(); } }
public void suspend() { removePolledAttributeListener(); cacheSamplesPanel.stop(); }
setMaximumSize(newPreferredSize); if (null == cacheSamplesScrollPane) { AggregateVuMeterPanel.this.revalidate(); } else { cacheSamplesScrollPane.revalidate();
protected AggregateVuMeterPanel(final ApplicationContext appContext, final boolean globalMode) { this.appContext = appContext; this.globalMode = globalMode; this.repaintCacheSamplesPanel = new Runnable() { public void run() { if (cacheSamplesPanel != null) { cacheSamplesPanel.repaint(); } } }; setLayout(new BorderLayout()); setup(); }
private XContainer createMainPanel(boolean globalMode) { XContainer panel = new XContainer(new BorderLayout()); panel.add(vuMeterPanel = new AggregateVuMeterPanel(appContext, globalMode), BorderLayout.CENTER); return panel; }
private void init() { if (!tornDown.get()) { vuMeterPanel.setup(appContext, clusterModel, persistenceUnit); } }
public void setup(ApplicationContext appContext, IClusterModel clusterModel, String persistenceUnit) { this.clusterModel = clusterModel; this.persistenceUnit = persistenceUnit; try { statsBeanObjectName = HibernateStatsUtils.getHibernateStatsBeanName(persistenceUnit); } catch (Exception e) { throw new RuntimeException(e); } clusterModel.addPropertyChangeListener(clusterListener = new ClusterListener(clusterModel)); if (clusterModel.isReady()) { init(); } }
public void suspend() { removePolledAttributeListener(); cacheSamplesPanel.stop(); }
setMaximumSize(newPreferredSize); if (null == cacheSamplesScrollPane) { AggregateVuMeterPanel.this.revalidate(); } else { cacheSamplesScrollPane.revalidate();
protected AggregateVuMeterPanel(final ApplicationContext appContext, final boolean globalMode) { this.appContext = appContext; this.globalMode = globalMode; this.repaintCacheSamplesPanel = new Runnable() { public void run() { if (cacheSamplesPanel != null) { cacheSamplesPanel.repaint(); } } }; setLayout(new BorderLayout()); setup(); }
protected void setupCacheSamplesPanel() { cacheSamplesPanel = new CacheSamplesPanel(); // only add scroll bars in per-region mode if (globalMode) { add(cacheSamplesPanel); } else { cacheSamplesScrollPane = new JScrollPane(cacheSamplesPanel); cacheSamplesScrollPane.setHorizontalScrollBarPolicy(ScrollPaneConstants.HORIZONTAL_SCROLLBAR_NEVER); cacheSamplesScrollPane.setVerticalScrollBarPolicy(ScrollPaneConstants.VERTICAL_SCROLLBAR_AS_NEEDED); cacheSamplesScrollPane.getVerticalScrollBar().setUnitIncrement(16); add(cacheSamplesScrollPane); } repaint(); }