1 22 package org.jboss.test.iiop.interfaces; 23 24 25 31 32 public abstract class IdlInterfacePOA extends org.omg.PortableServer.Servant 33 implements org.jboss.test.iiop.interfaces.IdlInterfaceOperations, org.omg.CORBA.portable.InvokeHandler 34 { 35 36 38 private static java.util.Hashtable _methods = new java.util.Hashtable (); 39 static 40 { 41 _methods.put ("echo", new java.lang.Integer (0)); 42 } 43 44 public org.omg.CORBA.portable.OutputStream _invoke (String $method, 45 org.omg.CORBA.portable.InputStream in, 46 org.omg.CORBA.portable.ResponseHandler $rh) 47 { 48 org.omg.CORBA.portable.OutputStream out = null; 49 java.lang.Integer __method = (java.lang.Integer )_methods.get ($method); 50 if (__method == null) 51 throw new org.omg.CORBA.BAD_OPERATION (0, org.omg.CORBA.CompletionStatus.COMPLETED_MAYBE); 52 53 switch (__method.intValue ()) 54 { 55 case 0: { 57 String s = in.read_string (); 58 String $result = null; 59 $result = this.echo (s); 60 out = $rh.createReply(); 61 out.write_string ($result); 62 break; 63 } 64 65 default: 66 throw new org.omg.CORBA.BAD_OPERATION (0, org.omg.CORBA.CompletionStatus.COMPLETED_MAYBE); 67 } 68 69 return out; 70 } 72 private static String [] __ids = { 74 "IDL:org/jboss/test/iiop/interfaces/IdlInterface:1.0"}; 75 76 public String [] _all_interfaces (org.omg.PortableServer.POA poa, byte[] objectId) 77 { 78 return (String [])__ids.clone (); 79 } 80 81 public IdlInterface _this() 82 { 83 return IdlInterfaceHelper.narrow( 84 super._this_object()); 85 } 86 87 public IdlInterface _this(org.omg.CORBA.ORB orb) 88 { 89 return IdlInterfaceHelper.narrow( 90 super._this_object(orb)); 91 } 92 93 94 } | Popular Tags |