1 package org.jacorb.poa; 2 3 22 23 import org.apache.avalon.framework.logger.Logger; 24 import org.apache.avalon.framework.configuration.*; 25 26 import org.jacorb.poa.gui.*; 27 import org.jacorb.util.ObjectUtil; 28 29 30 36 37 public class POAManagerMonitorLightImpl 38 implements POAManagerMonitor, Configurable 39 { 40 private POAManager model = null; 41 42 private org.jacorb.config.Configuration configuration = null; 43 private Logger logger; 44 private boolean doMonitor; 45 46 public void addPOA(String name) 47 { 48 } 49 50 public void closeMonitor() { 51 } 52 53 public void init(POAManager poaManager) 54 { 55 model = poaManager; 56 } 57 58 public void configure(Configuration myConfiguration) 59 throws ConfigurationException 60 { 61 this.configuration = (org.jacorb.config.Configuration)myConfiguration; 62 logger = configuration.getNamedLogger("jacorb.poa.manager_monitor"); 63 doMonitor = 64 configuration.getAttributeAsBoolean("jacorb.poa.monitoring",false); 65 } 66 67 public void openMonitor() 68 { 69 if ( doMonitor ) 70 { 71 try 72 { 73 POAManagerMonitor newMonitor = 74 (POAManagerMonitor)ObjectUtil.classForName("org.jacorb.poa.POAManagerMonitorImpl").newInstance(); 75 newMonitor.init(model); 76 newMonitor.configure(configuration); 77 model.setMonitor(newMonitor); 78 newMonitor.openMonitor(); 79 } 80 catch (Throwable exception) 81 { 82 if (logger.isErrorEnabled()) 83 logger.error( "Exception in closeMonitor(): " + exception.getMessage()); 84 } 85 } 86 } 87 public void printMessage(String str) { 88 } 89 public void removePOA(String name) { 90 } 91 public void setToActive() { 92 } 93 public void setToDiscarding(boolean wait) { 94 } 95 public void setToHolding(boolean wait) { 96 } 97 public void setToInactive(boolean wait, boolean etherialize) { 98 } 99 } 100 101 102 103 104 105 106 107 | Popular Tags |