1 28 29 30 package org.objectweb.corba.runtime; 31 32 36 public class DebugORBInitializerImpl 37 extends org.omg.CORBA.LocalObject 38 implements org.omg.PortableInterceptor.ORBInitializer 39 { 40 static final private String _class_name = "DebugORBInitializerImpl"; 42 43 public 44 DebugORBInitializerImpl() 45 { 46 } 47 48 52 final public void 53 pre_init(org.omg.PortableInterceptor.ORBInitInfo info) 54 { 55 String flag = System.getProperty("debug"); 57 if ((flag==null) || (!flag.equals("true"))) { 58 return ; 59 } 60 61 String opname = "pre_init"; 62 TheLogger.debug(_class_name, opname, ""); 63 TheLogger.debug(_class_name, opname, "ORB id: "+info.orb_id()); 64 } 69 70 final public void 71 post_init(org.omg.PortableInterceptor.ORBInitInfo info) 72 { 73 String flag = System.getProperty("debug"); 75 if ((flag==null) || (!flag.equals("true"))) { 76 return ; 77 } 78 79 String opname = "post_init"; 80 TheLogger.debug(_class_name, opname, ""); 81 82 try { 84 info.add_client_request_interceptor(new DebugCRIImpl()); 85 info.add_server_request_interceptor(new DebugSRIImpl()); 86 } catch (org.omg.PortableInterceptor.ORBInitInfoPackage.DuplicateName ex) { 87 TheLogger.debug(_class_name, opname, "IGNORE (PI not registered)", ex); 89 } 90 } 91 } 92 | Popular Tags |