1 7 14 15 package org.omg.CosNaming; 16 public abstract class _BindingIteratorImplBase extends org.omg.CORBA.DynamicImplementation implements org.omg.CosNaming.BindingIterator { 17 public _BindingIteratorImplBase() { 19 super(); 20 } 21 private static final String _type_ids[] = { 23 "IDL:omg.org/CosNaming/BindingIterator:1.0" 24 }; 25 26 public String [] _ids() { return (String []) _type_ids.clone(); } 27 28 private static java.util.Dictionary _methods = new java.util.Hashtable (); 29 static { 30 _methods.put("next_one", new java.lang.Integer (0)); 31 _methods.put("next_n", new java.lang.Integer (1)); 32 _methods.put("destroy", new java.lang.Integer (2)); 33 } 34 public void invoke(org.omg.CORBA.ServerRequest r) { 36 switch (((java.lang.Integer ) _methods.get(r.op_name())).intValue()) { 37 case 0: { 39 org.omg.CORBA.NVList _list = _orb().create_list(0); 40 org.omg.CORBA.Any _b = _orb().create_any(); 41 _b.type(org.omg.CosNaming.BindingHelper.type()); 42 _list.add_value("b", _b, org.omg.CORBA.ARG_OUT.value); 43 r.params(_list); 44 org.omg.CosNaming.BindingHolder b; 45 b = new org.omg.CosNaming.BindingHolder (); 46 boolean ___result; 47 ___result = this.next_one(b); 48 org.omg.CosNaming.BindingHelper.insert(_b, b.value); 49 org.omg.CORBA.Any __result = _orb().create_any(); 50 __result.insert_boolean(___result); 51 r.result(__result); 52 } 53 break; 54 case 1: { 56 org.omg.CORBA.NVList _list = _orb().create_list(0); 57 org.omg.CORBA.Any _how_many = _orb().create_any(); 58 _how_many.type(org.omg.CORBA.ORB.init().get_primitive_tc(org.omg.CORBA.TCKind.tk_ulong)); 59 _list.add_value("how_many", _how_many, org.omg.CORBA.ARG_IN.value); 60 org.omg.CORBA.Any _bl = _orb().create_any(); 61 _bl.type(org.omg.CosNaming.BindingListHelper.type()); 62 _list.add_value("bl", _bl, org.omg.CORBA.ARG_OUT.value); 63 r.params(_list); 64 int how_many; 65 how_many = _how_many.extract_ulong(); 66 org.omg.CosNaming.BindingListHolder bl; 67 bl = new org.omg.CosNaming.BindingListHolder (); 68 boolean ___result; 69 ___result = this.next_n(how_many, bl); 70 org.omg.CosNaming.BindingListHelper.insert(_bl, bl.value); 71 org.omg.CORBA.Any __result = _orb().create_any(); 72 __result.insert_boolean(___result); 73 r.result(__result); 74 } 75 break; 76 case 2: { 78 org.omg.CORBA.NVList _list = _orb().create_list(0); 79 r.params(_list); 80 this.destroy(); 81 org.omg.CORBA.Any __return = _orb().create_any(); 82 __return.type(_orb().get_primitive_tc(org.omg.CORBA.TCKind.tk_void)); 83 r.result(__return); 84 } 85 break; 86 default: 87 throw new org.omg.CORBA.BAD_OPERATION (0, org.omg.CORBA.CompletionStatus.COMPLETED_MAYBE); 88 } 89 } 90 } 91 | Popular Tags |