/// <summary>
		/// use stub to create a PriceList via web services
		/// </summary>
		/// <param name="PriceLists">Array of TCreate_Input</param>
		/// <returns>ArrayList of TCreate_Return</returns>
		public ArrayList create(TCreate_Input[] PriceLists)
		{
			TCreate_Return[] PriceLists_out = stub.create(PriceLists);

			ArrayList result = new ArrayList();

			for(int i = 0; i < PriceLists_out.Length; i++)
			{
				TCreate_Return PriceList_out = PriceLists_out[i];

				if (PriceList_out.Error == null)
				{
					Console.WriteLine("successfully created PriceList: " + PriceList_out.Path);
					result.Add(PriceList_out);
				}
				else
				{
					Console.WriteLine("an error occured (Epages Error):\n" + PriceList_out.Error.Message);
				}
			}

			return result;
		}
Exemplo n.º 2
0
 /// <remarks/>
 public System.IAsyncResult Begincreate(TCreate_Input[] PriceLists, System.AsyncCallback callback, object asyncState) {
     return this.BeginInvoke("create", new object[] {
                 PriceLists}, callback, asyncState);
 }
Exemplo n.º 3
0
 public TCreate_Return[] create(TCreate_Input[] PriceLists) {
     object[] results = this.Invoke("create", new object[] {
                 PriceLists});
     return ((TCreate_Return[])(results[0]));
 }
Exemplo n.º 4
0
		/// <summary>
		/// test creation of a PriceList and check if method returns a true value
		/// </summary>
		public void create()
		{
			TCreate_Input[] PriceLists = new TCreate_Input[]{PriceList_in};

			ArrayList PriceLists_out = serviceClient.create(PriceLists);

			// test if creation was successful
			Assert.AreEqual(1, PriceLists_out.Count, "create result set");

			TCreate_Return PriceList_out = (TCreate_Return)PriceLists_out.ToArray()[0];
			Assert.AreEqual(alias, PriceList_out.Alias, "PriceList alias");
			Assert.AreEqual(true, PriceList_out.created, "created?");
		}