001    package org.omg.CosTransactions;
002    
003    
004    /**
005    * org/omg/CosTransactions/_TransactionFactoryStub.java .
006    * Generated by the IDL-to-Java compiler (portable), version "3.2"
007    * from /builddir/build/BUILD/geronimo-specs-1.6/geronimo-spec-corba/src/main/idl/CosTransactions.idl
008    * Saturday, September 22, 2012 10:56:39 AM CEST
009    */
010    
011    public class _TransactionFactoryStub extends org.omg.CORBA.portable.ObjectImpl implements org.omg.CosTransactions.TransactionFactory
012    {
013    
014      public org.omg.CosTransactions.Control create (int time_out)
015      {
016                org.omg.CORBA.portable.InputStream $in = null;
017                try {
018                    org.omg.CORBA.portable.OutputStream $out = _request ("create", true);
019                    $out.write_ulong (time_out);
020                    $in = _invoke ($out);
021                    org.omg.CosTransactions.Control $result = org.omg.CosTransactions.ControlHelper.read ($in);
022                    return $result;
023                } catch (org.omg.CORBA.portable.ApplicationException $ex) {
024                    $in = $ex.getInputStream ();
025                    String _id = $ex.getId ();
026                    throw new org.omg.CORBA.MARSHAL (_id);
027                } catch (org.omg.CORBA.portable.RemarshalException $rm) {
028                    return create (time_out        );
029                } finally {
030                    _releaseReply ($in);
031                }
032      } // create
033    
034      public org.omg.CosTransactions.Control recreate (org.omg.CosTransactions.PropagationContext ctx)
035      {
036                org.omg.CORBA.portable.InputStream $in = null;
037                try {
038                    org.omg.CORBA.portable.OutputStream $out = _request ("recreate", true);
039                    org.omg.CosTransactions.PropagationContextHelper.write ($out, ctx);
040                    $in = _invoke ($out);
041                    org.omg.CosTransactions.Control $result = org.omg.CosTransactions.ControlHelper.read ($in);
042                    return $result;
043                } catch (org.omg.CORBA.portable.ApplicationException $ex) {
044                    $in = $ex.getInputStream ();
045                    String _id = $ex.getId ();
046                    throw new org.omg.CORBA.MARSHAL (_id);
047                } catch (org.omg.CORBA.portable.RemarshalException $rm) {
048                    return recreate (ctx        );
049                } finally {
050                    _releaseReply ($in);
051                }
052      } // recreate
053    
054      // Type-specific CORBA::Object operations
055      private static String[] __ids = {
056        "IDL:CosTransactions/TransactionFactory:1.0"};
057    
058      public String[] _ids ()
059      {
060        return (String[])__ids.clone ();
061      }
062    
063      private void readObject (java.io.ObjectInputStream s) throws java.io.IOException
064      {
065         String str = s.readUTF ();
066         String[] args = null;
067         java.util.Properties props = null;
068         org.omg.CORBA.Object obj = org.omg.CORBA.ORB.init (args, props).string_to_object (str);
069         org.omg.CORBA.portable.Delegate delegate = ((org.omg.CORBA.portable.ObjectImpl) obj)._get_delegate ();
070         _set_delegate (delegate);
071      }
072    
073      private void writeObject (java.io.ObjectOutputStream s) throws java.io.IOException
074      {
075         String[] args = null;
076         java.util.Properties props = null;
077         String str = org.omg.CORBA.ORB.init (args, props).object_to_string (this);
078         s.writeUTF (str);
079      }
080    } // class _TransactionFactoryStub