/**
 ** Please don't modify this file.
 ** This file was generated by the Software AG, EntireX Java Wrapper
 ** from the IDL file C:/Documents and Settings/Admin/Bureau/Brokers logistique/nwlwzom4/nwlwzom4.idl.
 **
 ** @author    Software AG
 ** @version   EntireX Wrapper, Version: 7.2.1.50, Date: 06 Mar 2006 (1.71.2.2)
 **
 **/

import java.util.Date;
import java.math.BigDecimal;
import com.softwareag.entirex.aci.*;

public class Jwlwzom4 extends RPCService {

	public static final String DEFAULT_BROKERID = "213.41.17.150:2200";
	public static final String DEFAULT_SERVER = "RPC/SRV1/CALLNAT";

	public Jwlwzom4() {
		super();
	}

	public Jwlwzom4(Broker broker) {
		this(broker, DEFAULT_SERVER);
	}

	public Jwlwzom4(BrokerService bs) {
		this(bs.getBroker(), bs.toString());
	}

	public Jwlwzom4(Broker broker, String serverAddr) {
		super(broker, serverAddr, "Jwlwzom4", true);
	}

	public static String getStubVersion() {
		return "EntireX RPC for Java Stub Version=7.2.1, Patch Level=50";
	}

	private Nwlwzom4Axwebent nwlwzom4Axwebent;

	public void setNwlwzom4Axwebent(Nwlwzom4Axwebent p) {
		nwlwzom4Axwebent = p;
	}

	public Nwlwzom4Axwebent getNwlwzom4Axwebent() {
		return nwlwzom4Axwebent;
	}

	private Nwlwzom4Awlwzom4 nwlwzom4Awlwzom4;

	public void setNwlwzom4Awlwzom4(Nwlwzom4Awlwzom4 p) {
		nwlwzom4Awlwzom4 = p;
	}

	public Nwlwzom4Awlwzom4 getNwlwzom4Awlwzom4() {
		return nwlwzom4Awlwzom4;
	}

	private final static byte[] NWLWZOM4_FORMAT =
			( "MG1,1MN3,0MA2,0MA8,0MN8,0MA8,0MA8,0MA8,0MA15,0MA2,0MA3,0MA3,"
			  + "0MA11,0MA8,0MA8,0MA1,0MN2,0MN1,0MG2,1,5MA4,0MA65,0MA1,0MN2,"
			  + "0MG2,0MG1,0MG1,1MG2,1MA4,0,40MA1,0,40MA5,0,40MG2,0MG1,0." ).getBytes();

	public void nwlwzom4() throws BrokerException {

		buildHeader (NWLWZOM4_FORMAT, "32", 868, 0, "NWLWZOM4", true, 1110, true, false, 2000);
if (nwlwzom4Axwebent == null) nwlwzom4Axwebent = new Nwlwzom4Axwebent();
		if ( getVersion() >= 2000 ) {
			nwlwzom4Axwebent.add();
		} else {
		super.marshal.addDataN(nwlwzom4Axwebent.dbid, 3, 0);
		super.marshal.addDataA(nwlwzom4Axwebent.cible_exploitant, 2);
		super.marshal.addDataA(nwlwzom4Axwebent.groupe_exploitant, 8);
		super.marshal.addDataN(nwlwzom4Axwebent.numero_session, 8, 0);
		super.marshal.addDataA(nwlwzom4Axwebent.utilisateur, 8);
		super.marshal.addDataA(nwlwzom4Axwebent.transaction, 8);
		super.marshal.addDataA(nwlwzom4Axwebent.fonction, 8);
		super.marshal.addDataA(nwlwzom4Axwebent.date_time_deb, 15);
		super.marshal.addDataA(nwlwzom4Axwebent.cd_cible, 2);
		super.marshal.addDataA(nwlwzom4Axwebent.cd_stegrp, 3);
		super.marshal.addDataA(nwlwzom4Axwebent.cd_titre, 3);
		super.marshal.addDataA(nwlwzom4Axwebent.num_cli_ref, 11);
		super.marshal.addDataA(nwlwzom4Axwebent.mot_passe_appl, 8);
		super.marshal.addDataA(nwlwzom4Axwebent.cd_application, 8);
		super.marshal.addDataA(nwlwzom4Axwebent.type_user, 1);
		super.marshal.addDataN(nwlwzom4Axwebent.code_retour, 2, 0);
		super.marshal.addDataN(nwlwzom4Axwebent.nb_ano, 1, 0);
		if (nwlwzom4Axwebent.t_ano == null) nwlwzom4Axwebent.t_ano = new Nwlwzom4AxwebentT_ano[5];
		for (int i0=0; i0<5; i0++) if (nwlwzom4Axwebent.t_ano[i0] == null) nwlwzom4Axwebent.t_ano[i0] = new Nwlwzom4AxwebentT_ano();
		for (int i0=0; i0<5; i0++) super.marshal.addDataA(nwlwzom4Axwebent.t_ano[i0].code_ano, 4);
		for (int i0=0; i0<5; i0++) super.marshal.addDataA(nwlwzom4Axwebent.t_ano[i0].lib_ano, 65);
		for (int i0=0; i0<5; i0++) super.marshal.addDataA(nwlwzom4Axwebent.t_ano[i0].type_ano, 1);
		for (int i0=0; i0<5; i0++) super.marshal.addDataN(nwlwzom4Axwebent.t_ano[i0].num_data, 2, 0);
		}
if (nwlwzom4Awlwzom4 == null) nwlwzom4Awlwzom4 = new Nwlwzom4Awlwzom4();
		if ( getVersion() >= 2000 ) {
			nwlwzom4Awlwzom4.add();
		} else {
if (nwlwzom4Awlwzom4.demande == null) nwlwzom4Awlwzom4.demande = new Nwlwzom4Awlwzom4Demande();
				if (nwlwzom4Awlwzom4.demande.cd_zpo == null) nwlwzom4Awlwzom4.demande.cd_zpo = new String[40];
		for (int i0=0; i0<40; i0++) super.marshal.addDataA(nwlwzom4Awlwzom4.demande.cd_zpo[i0], 4);
				if (nwlwzom4Awlwzom4.demande.type_portage == null) nwlwzom4Awlwzom4.demande.type_portage = new String[40];
		for (int i0=0; i0<40; i0++) super.marshal.addDataA(nwlwzom4Awlwzom4.demande.type_portage[i0], 1);
				if (nwlwzom4Awlwzom4.demande.zpo_ordre == null) nwlwzom4Awlwzom4.demande.zpo_ordre = new String[40];
		for (int i0=0; i0<40; i0++) super.marshal.addDataA(nwlwzom4Awlwzom4.demande.zpo_ordre[i0], 5);
		}

		callServer();

		if (nwlwzom4Axwebent == null) nwlwzom4Axwebent = new Nwlwzom4Axwebent();
		if ( getVersion() >= 2000 ) {
			nwlwzom4Axwebent.get();
		} else {
		nwlwzom4Axwebent.dbid = super.marshal.getDataN(3, 0);
		nwlwzom4Axwebent.cible_exploitant = super.marshal.getDataA(2);
		nwlwzom4Axwebent.groupe_exploitant = super.marshal.getDataA(8);
		nwlwzom4Axwebent.numero_session = super.marshal.getDataN(8, 0);
		nwlwzom4Axwebent.utilisateur = super.marshal.getDataA(8);
		nwlwzom4Axwebent.transaction = super.marshal.getDataA(8);
		nwlwzom4Axwebent.fonction = super.marshal.getDataA(8);
		nwlwzom4Axwebent.date_time_deb = super.marshal.getDataA(15);
		nwlwzom4Axwebent.cd_cible = super.marshal.getDataA(2);
		nwlwzom4Axwebent.cd_stegrp = super.marshal.getDataA(3);
		nwlwzom4Axwebent.cd_titre = super.marshal.getDataA(3);
		nwlwzom4Axwebent.num_cli_ref = super.marshal.getDataA(11);
		nwlwzom4Axwebent.mot_passe_appl = super.marshal.getDataA(8);
		nwlwzom4Axwebent.cd_application = super.marshal.getDataA(8);
		nwlwzom4Axwebent.type_user = super.marshal.getDataA(1);
		nwlwzom4Axwebent.code_retour = super.marshal.getDataN(2, 0);
		nwlwzom4Axwebent.nb_ano = super.marshal.getDataN(1, 0);
				if (nwlwzom4Axwebent.t_ano == null) nwlwzom4Axwebent.t_ano = new Nwlwzom4AxwebentT_ano[5];
		for (int i0=0; i0<5; i0++) if (nwlwzom4Axwebent.t_ano[i0] == null) nwlwzom4Axwebent.t_ano[i0] = new Nwlwzom4AxwebentT_ano();
		for (int i0=0; i0<5; i0++) nwlwzom4Axwebent.t_ano[i0].code_ano = super.marshal.getDataA(4);
		for (int i0=0; i0<5; i0++) nwlwzom4Axwebent.t_ano[i0].lib_ano = super.marshal.getDataA(65);
		for (int i0=0; i0<5; i0++) nwlwzom4Axwebent.t_ano[i0].type_ano = super.marshal.getDataA(1);
		for (int i0=0; i0<5; i0++) nwlwzom4Axwebent.t_ano[i0].num_data = super.marshal.getDataN(2, 0);
		}
		if (nwlwzom4Awlwzom4 == null) nwlwzom4Awlwzom4 = new Nwlwzom4Awlwzom4();
		if ( getVersion() >= 2000 ) {
			nwlwzom4Awlwzom4.get();
		} else {
		if (nwlwzom4Awlwzom4.demande == null) nwlwzom4Awlwzom4.demande = new Nwlwzom4Awlwzom4Demande();
		for (int i0=0; i0<40; i0++) nwlwzom4Awlwzom4.demande.cd_zpo[i0] = super.marshal.getDataA(4);
		for (int i0=0; i0<40; i0++) nwlwzom4Awlwzom4.demande.type_portage[i0] = super.marshal.getDataA(1);
		for (int i0=0; i0<40; i0++) nwlwzom4Awlwzom4.demande.zpo_ordre[i0] = super.marshal.getDataA(5);
		}

	}

	public class Nwlwzom4Axwebent {
		public BigDecimal dbid;
		public String cible_exploitant;
		public String groupe_exploitant;
		public BigDecimal numero_session;
		public String utilisateur;
		public String transaction;
		public String fonction;
		public String date_time_deb;
		public String cd_cible;
		public String cd_stegrp;
		public String cd_titre;
		public String num_cli_ref;
		public String mot_passe_appl;
		public String cd_application;
		public String type_user;
		public BigDecimal code_retour;
		public BigDecimal nb_ano;
		public Nwlwzom4AxwebentT_ano[] t_ano;
		public void add() throws BrokerException {
			Jwlwzom4.super.marshal.addDataN(dbid, 3, 0);
			Jwlwzom4.super.marshal.addDataA(cible_exploitant, 2);
			Jwlwzom4.super.marshal.addDataA(groupe_exploitant, 8);
			Jwlwzom4.super.marshal.addDataN(numero_session, 8, 0);
			Jwlwzom4.super.marshal.addDataA(utilisateur, 8);
			Jwlwzom4.super.marshal.addDataA(transaction, 8);
			Jwlwzom4.super.marshal.addDataA(fonction, 8);
			Jwlwzom4.super.marshal.addDataA(date_time_deb, 15);
			Jwlwzom4.super.marshal.addDataA(cd_cible, 2);
			Jwlwzom4.super.marshal.addDataA(cd_stegrp, 3);
			Jwlwzom4.super.marshal.addDataA(cd_titre, 3);
			Jwlwzom4.super.marshal.addDataA(num_cli_ref, 11);
			Jwlwzom4.super.marshal.addDataA(mot_passe_appl, 8);
			Jwlwzom4.super.marshal.addDataA(cd_application, 8);
			Jwlwzom4.super.marshal.addDataA(type_user, 1);
			Jwlwzom4.super.marshal.addDataN(code_retour, 2, 0);
			Jwlwzom4.super.marshal.addDataN(nb_ano, 1, 0);
			if (t_ano == null) t_ano = new Nwlwzom4AxwebentT_ano[5];
		for (int i0=0; i0<5; i0++) if (t_ano[i0] == null) t_ano[i0] = new Nwlwzom4AxwebentT_ano();
			for (int i0=0; i0<5; i0++) t_ano[i0].add();
		}
		public void get() throws BrokerException {
			dbid = Jwlwzom4.super.marshal.getDataN(3, 0);
			cible_exploitant = Jwlwzom4.super.marshal.getDataA(2);
			groupe_exploitant = Jwlwzom4.super.marshal.getDataA(8);
			numero_session = Jwlwzom4.super.marshal.getDataN(8, 0);
			utilisateur = Jwlwzom4.super.marshal.getDataA(8);
			transaction = Jwlwzom4.super.marshal.getDataA(8);
			fonction = Jwlwzom4.super.marshal.getDataA(8);
			date_time_deb = Jwlwzom4.super.marshal.getDataA(15);
			cd_cible = Jwlwzom4.super.marshal.getDataA(2);
			cd_stegrp = Jwlwzom4.super.marshal.getDataA(3);
			cd_titre = Jwlwzom4.super.marshal.getDataA(3);
			num_cli_ref = Jwlwzom4.super.marshal.getDataA(11);
			mot_passe_appl = Jwlwzom4.super.marshal.getDataA(8);
			cd_application = Jwlwzom4.super.marshal.getDataA(8);
			type_user = Jwlwzom4.super.marshal.getDataA(1);
			code_retour = Jwlwzom4.super.marshal.getDataN(2, 0);
			nb_ano = Jwlwzom4.super.marshal.getDataN(1, 0);
			if (t_ano == null) t_ano = new Nwlwzom4AxwebentT_ano[5];
		for (int i0=0; i0<5; i0++) if (t_ano[i0] == null) t_ano[i0] = new Nwlwzom4AxwebentT_ano();
			for (int i0=0; i0<5; i0++) {
				t_ano[i0].get();
			}
		}
	}

	public class Nwlwzom4AxwebentT_ano {
		public String code_ano;
		public String lib_ano;
		public String type_ano;
		public BigDecimal num_data;
		public void add() throws BrokerException {
			Jwlwzom4.super.marshal.addDataA(code_ano, 4);
			Jwlwzom4.super.marshal.addDataA(lib_ano, 65);
			Jwlwzom4.super.marshal.addDataA(type_ano, 1);
			Jwlwzom4.super.marshal.addDataN(num_data, 2, 0);
		}
		public void get() throws BrokerException {
			code_ano = Jwlwzom4.super.marshal.getDataA(4);
			lib_ano = Jwlwzom4.super.marshal.getDataA(65);
			type_ano = Jwlwzom4.super.marshal.getDataA(1);
			num_data = Jwlwzom4.super.marshal.getDataN(2, 0);
		}
	}

	public class Nwlwzom4Awlwzom4 {
		public Nwlwzom4Awlwzom4Demande demande;
		public void add() throws BrokerException {
			if (demande == null) demande = new Nwlwzom4Awlwzom4Demande();
			demande.add();
		}
		public void get() throws BrokerException {
			if (demande == null) demande = new Nwlwzom4Awlwzom4Demande();
							demande.get();
		}
	}

	public class Nwlwzom4Awlwzom4Demande {
		public String[] cd_zpo;
		public String[] type_portage;
		public String[] zpo_ordre;
		public void add() throws BrokerException {
			if (cd_zpo == null) cd_zpo = new String[40];
			for (int i0=0; i0<40; i0++) Jwlwzom4.super.marshal.addDataA(cd_zpo[i0], 4);
			if (type_portage == null) type_portage = new String[40];
			for (int i0=0; i0<40; i0++) Jwlwzom4.super.marshal.addDataA(type_portage[i0], 1);
			if (zpo_ordre == null) zpo_ordre = new String[40];
			for (int i0=0; i0<40; i0++) Jwlwzom4.super.marshal.addDataA(zpo_ordre[i0], 5);
		}
		public void get() throws BrokerException {
			if (cd_zpo == null) cd_zpo = new String[40];
			for (int i0=0; i0<40; i0++) cd_zpo[i0] = Jwlwzom4.super.marshal.getDataA(4);
			if (type_portage == null) type_portage = new String[40];
			for (int i0=0; i0<40; i0++) type_portage[i0] = Jwlwzom4.super.marshal.getDataA(1);
			if (zpo_ordre == null) zpo_ordre = new String[40];
			for (int i0=0; i0<40; i0++) zpo_ordre[i0] = Jwlwzom4.super.marshal.getDataA(5);
		}
	}

}
