1 package com.sun.corba.se.spi.activation; 2 3 4 10 11 public abstract class _ServerManagerImplBase extends org.omg.CORBA.portable.ObjectImpl 12 implements com.sun.corba.se.spi.activation.ServerManager, org.omg.CORBA.portable.InvokeHandler 13 { 14 15 public _ServerManagerImplBase () 17 { 18 } 19 20 private static java.util.Hashtable _methods = new java.util.Hashtable (); 21 static 22 { 23 _methods.put ("active", new java.lang.Integer (0)); 24 _methods.put ("registerEndpoints", new java.lang.Integer (1)); 25 _methods.put ("getActiveServers", new java.lang.Integer (2)); 26 _methods.put ("activate", new java.lang.Integer (3)); 27 _methods.put ("shutdown", new java.lang.Integer (4)); 28 _methods.put ("install", new java.lang.Integer (5)); 29 _methods.put ("getORBNames", new java.lang.Integer (6)); 30 _methods.put ("uninstall", new java.lang.Integer (7)); 31 _methods.put ("locateServer", new java.lang.Integer (8)); 32 _methods.put ("locateServerForORB", new java.lang.Integer (9)); 33 _methods.put ("getEndpoint", new java.lang.Integer (10)); 34 _methods.put ("getServerPortForType", new java.lang.Integer (11)); 35 } 36 37 public org.omg.CORBA.portable.OutputStream _invoke (String $method, 38 org.omg.CORBA.portable.InputStream in, 39 org.omg.CORBA.portable.ResponseHandler $rh) 40 { 41 org.omg.CORBA.portable.OutputStream out = null; 42 java.lang.Integer __method = (java.lang.Integer )_methods.get ($method); 43 if (__method == null) 44 throw new org.omg.CORBA.BAD_OPERATION (0, org.omg.CORBA.CompletionStatus.COMPLETED_MAYBE); 45 46 switch (__method.intValue ()) 47 { 48 49 case 0: { 52 try { 53 int serverId = com.sun.corba.se.spi.activation.ServerIdHelper.read (in); 54 com.sun.corba.se.spi.activation.Server serverObj = com.sun.corba.se.spi.activation.ServerHelper.read (in); 55 this.active (serverId, serverObj); 56 out = $rh.createReply(); 57 } catch (com.sun.corba.se.spi.activation.ServerNotRegistered $ex) { 58 out = $rh.createExceptionReply (); 59 com.sun.corba.se.spi.activation.ServerNotRegisteredHelper.write (out, $ex); 60 } 61 break; 62 } 63 64 65 case 1: { 68 try { 69 int serverId = com.sun.corba.se.spi.activation.ServerIdHelper.read (in); 70 String orbId = com.sun.corba.se.spi.activation.ORBidHelper.read (in); 71 com.sun.corba.se.spi.activation.EndPointInfo endPointInfo[] = com.sun.corba.se.spi.activation.EndpointInfoListHelper.read (in); 72 this.registerEndpoints (serverId, orbId, endPointInfo); 73 out = $rh.createReply(); 74 } catch (com.sun.corba.se.spi.activation.ServerNotRegistered $ex) { 75 out = $rh.createExceptionReply (); 76 com.sun.corba.se.spi.activation.ServerNotRegisteredHelper.write (out, $ex); 77 } catch (com.sun.corba.se.spi.activation.NoSuchEndPoint $ex) { 78 out = $rh.createExceptionReply (); 79 com.sun.corba.se.spi.activation.NoSuchEndPointHelper.write (out, $ex); 80 } catch (com.sun.corba.se.spi.activation.ORBAlreadyRegistered $ex) { 81 out = $rh.createExceptionReply (); 82 com.sun.corba.se.spi.activation.ORBAlreadyRegisteredHelper.write (out, $ex); 83 } 84 break; 85 } 86 87 88 case 2: { 91 int $result[] = null; 92 $result = this.getActiveServers (); 93 out = $rh.createReply(); 94 com.sun.corba.se.spi.activation.ServerIdsHelper.write (out, $result); 95 break; 96 } 97 98 99 case 3: { 102 try { 103 int serverId = com.sun.corba.se.spi.activation.ServerIdHelper.read (in); 104 this.activate (serverId); 105 out = $rh.createReply(); 106 } catch (com.sun.corba.se.spi.activation.ServerAlreadyActive $ex) { 107 out = $rh.createExceptionReply (); 108 com.sun.corba.se.spi.activation.ServerAlreadyActiveHelper.write (out, $ex); 109 } catch (com.sun.corba.se.spi.activation.ServerNotRegistered $ex) { 110 out = $rh.createExceptionReply (); 111 com.sun.corba.se.spi.activation.ServerNotRegisteredHelper.write (out, $ex); 112 } catch (com.sun.corba.se.spi.activation.ServerHeldDown $ex) { 113 out = $rh.createExceptionReply (); 114 com.sun.corba.se.spi.activation.ServerHeldDownHelper.write (out, $ex); 115 } 116 break; 117 } 118 119 120 case 4: { 123 try { 124 int serverId = com.sun.corba.se.spi.activation.ServerIdHelper.read (in); 125 this.shutdown (serverId); 126 out = $rh.createReply(); 127 } catch (com.sun.corba.se.spi.activation.ServerNotActive $ex) { 128 out = $rh.createExceptionReply (); 129 com.sun.corba.se.spi.activation.ServerNotActiveHelper.write (out, $ex); 130 } catch (com.sun.corba.se.spi.activation.ServerNotRegistered $ex) { 131 out = $rh.createExceptionReply (); 132 com.sun.corba.se.spi.activation.ServerNotRegisteredHelper.write (out, $ex); 133 } 134 break; 135 } 136 137 138 case 5: { 141 try { 142 int serverId = com.sun.corba.se.spi.activation.ServerIdHelper.read (in); 143 this.install (serverId); 144 out = $rh.createReply(); 145 } catch (com.sun.corba.se.spi.activation.ServerNotRegistered $ex) { 146 out = $rh.createExceptionReply (); 147 com.sun.corba.se.spi.activation.ServerNotRegisteredHelper.write (out, $ex); 148 } catch (com.sun.corba.se.spi.activation.ServerHeldDown $ex) { 149 out = $rh.createExceptionReply (); 150 com.sun.corba.se.spi.activation.ServerHeldDownHelper.write (out, $ex); 151 } catch (com.sun.corba.se.spi.activation.ServerAlreadyInstalled $ex) { 152 out = $rh.createExceptionReply (); 153 com.sun.corba.se.spi.activation.ServerAlreadyInstalledHelper.write (out, $ex); 154 } 155 break; 156 } 157 158 159 case 6: { 162 try { 163 int serverId = com.sun.corba.se.spi.activation.ServerIdHelper.read (in); 164 String $result[] = null; 165 $result = this.getORBNames (serverId); 166 out = $rh.createReply(); 167 com.sun.corba.se.spi.activation.ORBidListHelper.write (out, $result); 168 } catch (com.sun.corba.se.spi.activation.ServerNotRegistered $ex) { 169 out = $rh.createExceptionReply (); 170 com.sun.corba.se.spi.activation.ServerNotRegisteredHelper.write (out, $ex); 171 } 172 break; 173 } 174 175 176 case 7: { 179 try { 180 int serverId = com.sun.corba.se.spi.activation.ServerIdHelper.read (in); 181 this.uninstall (serverId); 182 out = $rh.createReply(); 183 } catch (com.sun.corba.se.spi.activation.ServerNotRegistered $ex) { 184 out = $rh.createExceptionReply (); 185 com.sun.corba.se.spi.activation.ServerNotRegisteredHelper.write (out, $ex); 186 } catch (com.sun.corba.se.spi.activation.ServerHeldDown $ex) { 187 out = $rh.createExceptionReply (); 188 com.sun.corba.se.spi.activation.ServerHeldDownHelper.write (out, $ex); 189 } catch (com.sun.corba.se.spi.activation.ServerAlreadyUninstalled $ex) { 190 out = $rh.createExceptionReply (); 191 com.sun.corba.se.spi.activation.ServerAlreadyUninstalledHelper.write (out, $ex); 192 } 193 break; 194 } 195 196 197 case 8: { 200 try { 201 int serverId = com.sun.corba.se.spi.activation.ServerIdHelper.read (in); 202 String endPoint = in.read_string (); 203 com.sun.corba.se.spi.activation.LocatorPackage.ServerLocation $result = null; 204 $result = this.locateServer (serverId, endPoint); 205 out = $rh.createReply(); 206 com.sun.corba.se.spi.activation.LocatorPackage.ServerLocationHelper.write (out, $result); 207 } catch (com.sun.corba.se.spi.activation.NoSuchEndPoint $ex) { 208 out = $rh.createExceptionReply (); 209 com.sun.corba.se.spi.activation.NoSuchEndPointHelper.write (out, $ex); 210 } catch (com.sun.corba.se.spi.activation.ServerNotRegistered $ex) { 211 out = $rh.createExceptionReply (); 212 com.sun.corba.se.spi.activation.ServerNotRegisteredHelper.write (out, $ex); 213 } catch (com.sun.corba.se.spi.activation.ServerHeldDown $ex) { 214 out = $rh.createExceptionReply (); 215 com.sun.corba.se.spi.activation.ServerHeldDownHelper.write (out, $ex); 216 } 217 break; 218 } 219 220 221 case 9: { 224 try { 225 int serverId = com.sun.corba.se.spi.activation.ServerIdHelper.read (in); 226 String orbId = com.sun.corba.se.spi.activation.ORBidHelper.read (in); 227 com.sun.corba.se.spi.activation.LocatorPackage.ServerLocationPerORB $result = null; 228 $result = this.locateServerForORB (serverId, orbId); 229 out = $rh.createReply(); 230 com.sun.corba.se.spi.activation.LocatorPackage.ServerLocationPerORBHelper.write (out, $result); 231 } catch (com.sun.corba.se.spi.activation.InvalidORBid $ex) { 232 out = $rh.createExceptionReply (); 233 com.sun.corba.se.spi.activation.InvalidORBidHelper.write (out, $ex); 234 } catch (com.sun.corba.se.spi.activation.ServerNotRegistered $ex) { 235 out = $rh.createExceptionReply (); 236 com.sun.corba.se.spi.activation.ServerNotRegisteredHelper.write (out, $ex); 237 } catch (com.sun.corba.se.spi.activation.ServerHeldDown $ex) { 238 out = $rh.createExceptionReply (); 239 com.sun.corba.se.spi.activation.ServerHeldDownHelper.write (out, $ex); 240 } 241 break; 242 } 243 244 245 case 10: { 248 try { 249 String endPointType = in.read_string (); 250 int $result = (int)0; 251 $result = this.getEndpoint (endPointType); 252 out = $rh.createReply(); 253 out.write_long ($result); 254 } catch (com.sun.corba.se.spi.activation.NoSuchEndPoint $ex) { 255 out = $rh.createExceptionReply (); 256 com.sun.corba.se.spi.activation.NoSuchEndPointHelper.write (out, $ex); 257 } 258 break; 259 } 260 261 262 case 11: { 265 try { 266 com.sun.corba.se.spi.activation.LocatorPackage.ServerLocationPerORB location = com.sun.corba.se.spi.activation.LocatorPackage.ServerLocationPerORBHelper.read (in); 267 String endPointType = in.read_string (); 268 int $result = (int)0; 269 $result = this.getServerPortForType (location, endPointType); 270 out = $rh.createReply(); 271 out.write_long ($result); 272 } catch (com.sun.corba.se.spi.activation.NoSuchEndPoint $ex) { 273 out = $rh.createExceptionReply (); 274 com.sun.corba.se.spi.activation.NoSuchEndPointHelper.write (out, $ex); 275 } 276 break; 277 } 278 279 default: 280 throw new org.omg.CORBA.BAD_OPERATION (0, org.omg.CORBA.CompletionStatus.COMPLETED_MAYBE); 281 } 282 283 return out; 284 } 286 private static String [] __ids = { 288 "IDL:activation/ServerManager:1.0", 289 "IDL:activation/Activator:1.0", 290 "IDL:activation/Locator:1.0"}; 291 292 public String [] _ids () 293 { 294 return (String [])__ids.clone (); 295 } 296 297 298 } | Popular Tags |