1 23 24 28 package com.sun.jts.otsidl; 29 30 31 37 38 39 public class _JCoordinatorStub extends org.omg.CORBA.portable.ObjectImpl implements com.sun.jts.otsidl.JCoordinator 41 { 42 43 public org.omg.CosTransactions.otid_t getGlobalTID () 44 { 45 org.omg.CORBA.portable.InputStream $in = null; 46 try { 47 org.omg.CORBA.portable.OutputStream $out = _request ("getGlobalTID", true); 48 $in = _invoke ($out); 49 org.omg.CosTransactions.otid_t $result = org.omg.CosTransactions.otid_tHelper.read ($in); 50 return $result; 51 } catch (org.omg.CORBA.portable.ApplicationException $ex) { 52 $in = $ex.getInputStream (); 53 String _id = $ex.getId (); 54 throw new org.omg.CORBA.MARSHAL (_id); 55 } catch (org.omg.CORBA.portable.RemarshalException $rm) { 56 return getGlobalTID (); 57 } finally { 58 _releaseReply ($in); 59 } 60 } 62 63 public long getLocalTID () 65 { 66 org.omg.CORBA.portable.InputStream $in = null; 67 try { 68 org.omg.CORBA.portable.OutputStream $out = _request ("getLocalTID", true); 69 $in = _invoke ($out); 70 long $result = $in.read_longlong (); 71 return $result; 72 } catch (org.omg.CORBA.portable.ApplicationException $ex) { 73 $in = $ex.getInputStream (); 74 String _id = $ex.getId (); 75 throw new org.omg.CORBA.MARSHAL (_id); 76 } catch (org.omg.CORBA.portable.RemarshalException $rm) { 77 return getLocalTID (); 78 } finally { 79 _releaseReply ($in); 80 } 81 } 83 84 public org.omg.CosTransactions.TransIdentity[] getAncestors () 86 { 87 org.omg.CORBA.portable.InputStream $in = null; 88 try { 89 org.omg.CORBA.portable.OutputStream $out = _request ("getAncestors", true); 90 $in = _invoke ($out); 91 org.omg.CosTransactions.TransIdentity $result[] = com.sun.jts.otsidl.TransAncestryHelper.read ($in); 92 return $result; 93 } catch (org.omg.CORBA.portable.ApplicationException $ex) { 94 $in = $ex.getInputStream (); 95 String _id = $ex.getId (); 96 throw new org.omg.CORBA.MARSHAL (_id); 97 } catch (org.omg.CORBA.portable.RemarshalException $rm) { 98 return getAncestors (); 99 } finally { 100 _releaseReply ($in); 101 } 102 } 104 105 public boolean isRollbackOnly () 107 { 108 org.omg.CORBA.portable.InputStream $in = null; 109 try { 110 org.omg.CORBA.portable.OutputStream $out = _request ("isRollbackOnly", true); 111 $in = _invoke ($out); 112 boolean $result = $in.read_boolean (); 113 return $result; 114 } catch (org.omg.CORBA.portable.ApplicationException $ex) { 115 $in = $ex.getInputStream (); 116 String _id = $ex.getId (); 117 throw new org.omg.CORBA.MARSHAL (_id); 118 } catch (org.omg.CORBA.portable.RemarshalException $rm) { 119 return isRollbackOnly (); 120 } finally { 121 _releaseReply ($in); 122 } 123 } 125 public org.omg.CosTransactions.Status get_status () 126 { 127 org.omg.CORBA.portable.InputStream $in = null; 128 try { 129 org.omg.CORBA.portable.OutputStream $out = _request ("get_status", true); 130 $in = _invoke ($out); 131 org.omg.CosTransactions.Status $result = org.omg.CosTransactions.StatusHelper.read ($in); 132 return $result; 133 } catch (org.omg.CORBA.portable.ApplicationException $ex) { 134 $in = $ex.getInputStream (); 135 String _id = $ex.getId (); 136 throw new org.omg.CORBA.MARSHAL (_id); 137 } catch (org.omg.CORBA.portable.RemarshalException $rm) { 138 return get_status (); 139 } finally { 140 _releaseReply ($in); 141 } 142 } 144 public org.omg.CosTransactions.Status get_parent_status () 145 { 146 org.omg.CORBA.portable.InputStream $in = null; 147 try { 148 org.omg.CORBA.portable.OutputStream $out = _request ("get_parent_status", true); 149 $in = _invoke ($out); 150 org.omg.CosTransactions.Status $result = org.omg.CosTransactions.StatusHelper.read ($in); 151 return $result; 152 } catch (org.omg.CORBA.portable.ApplicationException $ex) { 153 $in = $ex.getInputStream (); 154 String _id = $ex.getId (); 155 throw new org.omg.CORBA.MARSHAL (_id); 156 } catch (org.omg.CORBA.portable.RemarshalException $rm) { 157 return get_parent_status (); 158 } finally { 159 _releaseReply ($in); 160 } 161 } 163 public org.omg.CosTransactions.Status get_top_level_status () 164 { 165 org.omg.CORBA.portable.InputStream $in = null; 166 try { 167 org.omg.CORBA.portable.OutputStream $out = _request ("get_top_level_status", true); 168 $in = _invoke ($out); 169 org.omg.CosTransactions.Status $result = org.omg.CosTransactions.StatusHelper.read ($in); 170 return $result; 171 } catch (org.omg.CORBA.portable.ApplicationException $ex) { 172 $in = $ex.getInputStream (); 173 String _id = $ex.getId (); 174 throw new org.omg.CORBA.MARSHAL (_id); 175 } catch (org.omg.CORBA.portable.RemarshalException $rm) { 176 return get_top_level_status (); 177 } finally { 178 _releaseReply ($in); 179 } 180 } 182 public boolean is_same_transaction (org.omg.CosTransactions.Coordinator tc) 183 { 184 org.omg.CORBA.portable.InputStream $in = null; 185 try { 186 org.omg.CORBA.portable.OutputStream $out = _request ("is_same_transaction", true); 187 org.omg.CosTransactions.CoordinatorHelper.write ($out, tc); 188 $in = _invoke ($out); 189 boolean $result = $in.read_boolean (); 190 return $result; 191 } catch (org.omg.CORBA.portable.ApplicationException $ex) { 192 $in = $ex.getInputStream (); 193 String _id = $ex.getId (); 194 throw new org.omg.CORBA.MARSHAL (_id); 195 } catch (org.omg.CORBA.portable.RemarshalException $rm) { 196 return is_same_transaction (tc); 197 } finally { 198 _releaseReply ($in); 199 } 200 } 202 public boolean is_related_transaction (org.omg.CosTransactions.Coordinator tc) 203 { 204 org.omg.CORBA.portable.InputStream $in = null; 205 try { 206 org.omg.CORBA.portable.OutputStream $out = _request ("is_related_transaction", true); 207 org.omg.CosTransactions.CoordinatorHelper.write ($out, tc); 208 $in = _invoke ($out); 209 boolean $result = $in.read_boolean (); 210 return $result; 211 } catch (org.omg.CORBA.portable.ApplicationException $ex) { 212 $in = $ex.getInputStream (); 213 String _id = $ex.getId (); 214 throw new org.omg.CORBA.MARSHAL (_id); 215 } catch (org.omg.CORBA.portable.RemarshalException $rm) { 216 return is_related_transaction (tc); 217 } finally { 218 _releaseReply ($in); 219 } 220 } 222 public boolean is_ancestor_transaction (org.omg.CosTransactions.Coordinator tc) 223 { 224 org.omg.CORBA.portable.InputStream $in = null; 225 try { 226 org.omg.CORBA.portable.OutputStream $out = _request ("is_ancestor_transaction", true); 227 org.omg.CosTransactions.CoordinatorHelper.write ($out, tc); 228 $in = _invoke ($out); 229 boolean $result = $in.read_boolean (); 230 return $result; 231 } catch (org.omg.CORBA.portable.ApplicationException $ex) { 232 $in = $ex.getInputStream (); 233 String _id = $ex.getId (); 234 throw new org.omg.CORBA.MARSHAL (_id); 235 } catch (org.omg.CORBA.portable.RemarshalException $rm) { 236 return is_ancestor_transaction (tc); 237 } finally { 238 _releaseReply ($in); 239 } 240 } 242 public boolean is_descendant_transaction (org.omg.CosTransactions.Coordinator tc) 243 { 244 org.omg.CORBA.portable.InputStream $in = null; 245 try { 246 org.omg.CORBA.portable.OutputStream $out = _request ("is_descendant_transaction", true); 247 org.omg.CosTransactions.CoordinatorHelper.write ($out, tc); 248 $in = _invoke ($out); 249 boolean $result = $in.read_boolean (); 250 return $result; 251 } catch (org.omg.CORBA.portable.ApplicationException $ex) { 252 $in = $ex.getInputStream (); 253 String _id = $ex.getId (); 254 throw new org.omg.CORBA.MARSHAL (_id); 255 } catch (org.omg.CORBA.portable.RemarshalException $rm) { 256 return is_descendant_transaction (tc); 257 } finally { 258 _releaseReply ($in); 259 } 260 } 262 public boolean is_top_level_transaction () 263 { 264 org.omg.CORBA.portable.InputStream $in = null; 265 try { 266 org.omg.CORBA.portable.OutputStream $out = _request ("is_top_level_transaction", true); 267 $in = _invoke ($out); 268 boolean $result = $in.read_boolean (); 269 return $result; 270 } catch (org.omg.CORBA.portable.ApplicationException $ex) { 271 $in = $ex.getInputStream (); 272 String _id = $ex.getId (); 273 throw new org.omg.CORBA.MARSHAL (_id); 274 } catch (org.omg.CORBA.portable.RemarshalException $rm) { 275 return is_top_level_transaction (); 276 } finally { 277 _releaseReply ($in); 278 } 279 } 281 public int hash_transaction () 282 { 283 org.omg.CORBA.portable.InputStream $in = null; 284 try { 285 org.omg.CORBA.portable.OutputStream $out = _request ("hash_transaction", true); 286 $in = _invoke ($out); 287 int $result = $in.read_ulong (); 288 return $result; 289 } catch (org.omg.CORBA.portable.ApplicationException $ex) { 290 $in = $ex.getInputStream (); 291 String _id = $ex.getId (); 292 throw new org.omg.CORBA.MARSHAL (_id); 293 } catch (org.omg.CORBA.portable.RemarshalException $rm) { 294 return hash_transaction (); 295 } finally { 296 _releaseReply ($in); 297 } 298 } 300 public int hash_top_level_tran () 301 { 302 org.omg.CORBA.portable.InputStream $in = null; 303 try { 304 org.omg.CORBA.portable.OutputStream $out = _request ("hash_top_level_tran", true); 305 $in = _invoke ($out); 306 int $result = $in.read_ulong (); 307 return $result; 308 } catch (org.omg.CORBA.portable.ApplicationException $ex) { 309 $in = $ex.getInputStream (); 310 String _id = $ex.getId (); 311 throw new org.omg.CORBA.MARSHAL (_id); 312 } catch (org.omg.CORBA.portable.RemarshalException $rm) { 313 return hash_top_level_tran (); 314 } finally { 315 _releaseReply ($in); 316 } 317 } 319 public org.omg.CosTransactions.RecoveryCoordinator register_resource (org.omg.CosTransactions.Resource r) throws org.omg.CosTransactions.Inactive 320 { 321 org.omg.CORBA.portable.InputStream $in = null; 322 try { 323 org.omg.CORBA.portable.OutputStream $out = _request ("register_resource", true); 324 org.omg.CosTransactions.ResourceHelper.write ($out, r); 325 $in = _invoke ($out); 326 org.omg.CosTransactions.RecoveryCoordinator $result = org.omg.CosTransactions.RecoveryCoordinatorHelper.read ($in); 327 return $result; 328 } catch (org.omg.CORBA.portable.ApplicationException $ex) { 329 $in = $ex.getInputStream (); 330 String _id = $ex.getId (); 331 if (_id.equals ("IDL:omg.org/CosTransactions/Inactive:1.0")) 332 throw org.omg.CosTransactions.InactiveHelper.read ($in); 333 else 334 throw new org.omg.CORBA.MARSHAL (_id); 335 } catch (org.omg.CORBA.portable.RemarshalException $rm) { 336 return register_resource (r); 337 } finally { 338 _releaseReply ($in); 339 } 340 } 342 public void register_synchronization (org.omg.CosTransactions.Synchronization sync) throws org.omg.CosTransactions.Inactive, org.omg.CosTransactions.SynchronizationUnavailable 343 { 344 org.omg.CORBA.portable.InputStream $in = null; 345 try { 346 org.omg.CORBA.portable.OutputStream $out = _request ("register_synchronization", true); 347 org.omg.CosTransactions.SynchronizationHelper.write ($out, sync); 348 $in = _invoke ($out); 349 } catch (org.omg.CORBA.portable.ApplicationException $ex) { 350 $in = $ex.getInputStream (); 351 String _id = $ex.getId (); 352 if (_id.equals ("IDL:omg.org/CosTransactions/Inactive:1.0")) 353 throw org.omg.CosTransactions.InactiveHelper.read ($in); 354 else if (_id.equals ("IDL:omg.org/CosTransactions/SynchronizationUnavailable:1.0")) 355 throw org.omg.CosTransactions.SynchronizationUnavailableHelper.read ($in); 356 else 357 throw new org.omg.CORBA.MARSHAL (_id); 358 } catch (org.omg.CORBA.portable.RemarshalException $rm) { 359 register_synchronization (sync); 360 } finally { 361 _releaseReply ($in); 362 } 363 } 365 public void register_subtran_aware (org.omg.CosTransactions.SubtransactionAwareResource r) throws org.omg.CosTransactions.Inactive, org.omg.CosTransactions.NotSubtransaction 366 { 367 org.omg.CORBA.portable.InputStream $in = null; 368 try { 369 org.omg.CORBA.portable.OutputStream $out = _request ("register_subtran_aware", true); 370 org.omg.CosTransactions.SubtransactionAwareResourceHelper.write ($out, r); 371 $in = _invoke ($out); 372 } catch (org.omg.CORBA.portable.ApplicationException $ex) { 373 $in = $ex.getInputStream (); 374 String _id = $ex.getId (); 375 if (_id.equals ("IDL:omg.org/CosTransactions/Inactive:1.0")) 376 throw org.omg.CosTransactions.InactiveHelper.read ($in); 377 else if (_id.equals ("IDL:omg.org/CosTransactions/NotSubtransaction:1.0")) 378 throw org.omg.CosTransactions.NotSubtransactionHelper.read ($in); 379 else 380 throw new org.omg.CORBA.MARSHAL (_id); 381 } catch (org.omg.CORBA.portable.RemarshalException $rm) { 382 register_subtran_aware (r); 383 } finally { 384 _releaseReply ($in); 385 } 386 } 388 public void rollback_only () throws org.omg.CosTransactions.Inactive 389 { 390 org.omg.CORBA.portable.InputStream $in = null; 391 try { 392 org.omg.CORBA.portable.OutputStream $out = _request ("rollback_only", true); 393 $in = _invoke ($out); 394 } catch (org.omg.CORBA.portable.ApplicationException $ex) { 395 $in = $ex.getInputStream (); 396 String _id = $ex.getId (); 397 if (_id.equals ("IDL:omg.org/CosTransactions/Inactive:1.0")) 398 throw org.omg.CosTransactions.InactiveHelper.read ($in); 399 else 400 throw new org.omg.CORBA.MARSHAL (_id); 401 } catch (org.omg.CORBA.portable.RemarshalException $rm) { 402 rollback_only (); 403 } finally { 404 _releaseReply ($in); 405 } 406 } 408 public String get_transaction_name () 409 { 410 org.omg.CORBA.portable.InputStream $in = null; 411 try { 412 org.omg.CORBA.portable.OutputStream $out = _request ("get_transaction_name", true); 413 $in = _invoke ($out); 414 String $result = $in.read_string (); 415 return $result; 416 } catch (org.omg.CORBA.portable.ApplicationException $ex) { 417 $in = $ex.getInputStream (); 418 String _id = $ex.getId (); 419 throw new org.omg.CORBA.MARSHAL (_id); 420 } catch (org.omg.CORBA.portable.RemarshalException $rm) { 421 return get_transaction_name (); 422 } finally { 423 _releaseReply ($in); 424 } 425 } 427 public org.omg.CosTransactions.Control create_subtransaction () throws org.omg.CosTransactions.SubtransactionsUnavailable, org.omg.CosTransactions.Inactive 428 { 429 org.omg.CORBA.portable.InputStream $in = null; 430 try { 431 org.omg.CORBA.portable.OutputStream $out = _request ("create_subtransaction", true); 432 $in = _invoke ($out); 433 org.omg.CosTransactions.Control $result = org.omg.CosTransactions.ControlHelper.read ($in); 434 return $result; 435 } catch (org.omg.CORBA.portable.ApplicationException $ex) { 436 $in = $ex.getInputStream (); 437 String _id = $ex.getId (); 438 if (_id.equals ("IDL:omg.org/CosTransactions/SubtransactionsUnavailable:1.0")) 439 throw org.omg.CosTransactions.SubtransactionsUnavailableHelper.read ($in); 440 else if (_id.equals ("IDL:omg.org/CosTransactions/Inactive:1.0")) 441 throw org.omg.CosTransactions.InactiveHelper.read ($in); 442 else 443 throw new org.omg.CORBA.MARSHAL (_id); 444 } catch (org.omg.CORBA.portable.RemarshalException $rm) { 445 return create_subtransaction (); 446 } finally { 447 _releaseReply ($in); 448 } 449 } 451 public org.omg.CosTransactions.PropagationContext get_txcontext () throws org.omg.CosTransactions.Unavailable 452 { 453 org.omg.CORBA.portable.InputStream $in = null; 454 try { 455 org.omg.CORBA.portable.OutputStream $out = _request ("get_txcontext", true); 456 $in = _invoke ($out); 457 org.omg.CosTransactions.PropagationContext $result = org.omg.CosTransactions.PropagationContextHelper.read ($in); 458 return $result; 459 } catch (org.omg.CORBA.portable.ApplicationException $ex) { 460 $in = $ex.getInputStream (); 461 String _id = $ex.getId (); 462 if (_id.equals ("IDL:omg.org/CosTransactions/Unavailable:1.0")) 463 throw org.omg.CosTransactions.UnavailableHelper.read ($in); 464 else 465 throw new org.omg.CORBA.MARSHAL (_id); 466 } catch (org.omg.CORBA.portable.RemarshalException $rm) { 467 return get_txcontext (); 468 } finally { 469 _releaseReply ($in); 470 } 471 } 473 private static String [] __ids = { 475 "IDL:otsidl/JCoordinator:1.0", 476 "IDL:omg.org/CosTransactions/Coordinator:1.0"}; 477 478 public String [] _ids () 479 { 480 return (String [])__ids.clone (); 481 } 482 483 private void readObject (java.io.ObjectInputStream s) throws java.io.IOException 484 { 485 String str = s.readUTF (); 486 String [] args = null; 487 java.util.Properties props = null; 488 org.omg.CORBA.Object obj = org.omg.CORBA.ORB.init (args, props).string_to_object (str); 489 org.omg.CORBA.portable.Delegate delegate = ((org.omg.CORBA.portable.ObjectImpl ) obj)._get_delegate (); 490 _set_delegate (delegate); 491 } 492 493 private void writeObject (java.io.ObjectOutputStream s) throws java.io.IOException 494 { 495 String [] args = null; 496 java.util.Properties props = null; 497 String str = org.omg.CORBA.ORB.init (args, props).object_to_string (this); 498 s.writeUTF (str); 499 } 500 } | Popular Tags |