1 29 30 package com.caucho.iiop.orb; 31 32 import com.caucho.iiop.*; 33 34 import org.omg.CORBA.*; 35 36 import java.util.logging.Logger ; 37 38 public class StubImpl extends javax.rmi.CORBA.Stub 39 { 40 public static final Logger log 41 = Logger.getLogger(StubImpl.class.getName()); 42 43 private ORBImpl _orb; 44 private IOR _ior; 45 46 StubImpl(ORBImpl orb) 47 { 48 _orb = orb; 49 50 _set_delegate(orb.getStubDelegate()); 51 } 52 53 public StubImpl(ORBImpl orb, IOR ior) 54 { 55 _orb = orb; 56 _ior = ior; 57 58 _set_delegate(orb.getStubDelegate()); 59 } 60 61 public String []_ids() 62 { 63 throw new UnsupportedOperationException (); 64 } 65 66 public IOR getIOR() 67 { 68 return _ior; 69 } 70 71 public byte []getOid() 72 { 73 if (_ior != null) 74 return _ior.getOid(); 75 else 76 return "INIT".getBytes(); 77 } 78 79 public String toString() 80 { 81 if (_ior != null) 82 return "StubImpl[" + _ior + "]"; 83 else 84 return "StubImpl[]"; 85 } 86 } 87 | Popular Tags |