All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.omg.XA.XIDsHelper Maven / Gradle / Ivy

package org.omg.XA;

/**
 * Generated from IDL alias "XIDs".
 *
 * @author JacORB IDL compiler V 2.3.1 (JBoss patch01), 29-Jul-2009
 * @version generated at Oct 2, 2012 3:07:47 PM
 */

public final class XIDsHelper
{
	private static org.omg.CORBA.TypeCode _type = null;

	public static void insert (org.omg.CORBA.Any any, org.omg.CosTransactions.otid_t[] s)
	{
		any.type (type ());
		write (any.create_output_stream (), s);
	}

	public static org.omg.CosTransactions.otid_t[] extract (final org.omg.CORBA.Any any)
	{
		return read (any.create_input_stream ());
	}

	public static org.omg.CORBA.TypeCode type ()
	{
		if (_type == null)
		{
			_type = org.omg.CORBA.ORB.init().create_alias_tc(org.omg.XA.XIDsHelper.id(), "XIDs",org.omg.CORBA.ORB.init().create_sequence_tc(0, org.omg.CosTransactions.otid_tHelper.type()));
		}
		return _type;
	}

	public static String id()
	{
		return "IDL:omg.org/XA/XIDs:1.0";
	}
	public static org.omg.CosTransactions.otid_t[] read (final org.omg.CORBA.portable.InputStream _in)
	{
		org.omg.CosTransactions.otid_t[] _result;
		int _l_result0 = _in.read_long();
		try
		{
			 int x = _in.available();
			 if ( x > 0 && _l_result0 > x )
				{
					throw new org.omg.CORBA.MARSHAL("Sequence length too large. Only " + x + " available and trying to assign " + _l_result0);
				}
		}
		catch (java.io.IOException e)
		{
		}
		_result = new org.omg.CosTransactions.otid_t[_l_result0];
		for (int i=0;i<_result.length;i++)
		{
			_result[i]=org.omg.CosTransactions.otid_tHelper.read(_in);
		}

		return _result;
	}

	public static void write (final org.omg.CORBA.portable.OutputStream _out, org.omg.CosTransactions.otid_t[] _s)
	{
		
		_out.write_long(_s.length);
		for (int i=0; i<_s.length;i++)
		{
			org.omg.CosTransactions.otid_tHelper.write(_out,_s[i]);
		}

	}
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy