/// <summary>
		/// use stub to create a Product via web services
		/// </summary>
		/// <param name="Products">Array of TUpdate_Input</param>
		/// <returns>ArrayList of TUpdate_Return</returns>
		public ArrayList update(TUpdate_Input[] Products) 
		{
			TUpdate_Return[] Products_out = stub.update(Products);

			ArrayList result = new ArrayList();

			for(int i = 0; i < Products_out.Length; i++)
			{
				TUpdate_Return Product_out = Products_out[i];

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

			return result;
		}
示例#2
0
 /// <remarks/>
 public System.IAsyncResult Beginupdate(TUpdate_Input[] Products, System.AsyncCallback callback, object asyncState) {
     return this.BeginInvoke("update", new object[] {
                 Products}, callback, asyncState);
 }
示例#3
0
 public TUpdate_Return[] update(TUpdate_Input[] Products) {
     object[] results = this.Invoke("update", new object[] {
                 Products});
     return ((TUpdate_Return[])(results[0]));
 }
示例#4
0
		/// <summary>
		/// test update of a Product and check if method returns a true value
		/// </summary>
		public void update()
		{
			TUpdate_Input[] Products = new TUpdate_Input[]{Product_update};

			ArrayList Products_out = serviceClient.update(Products);

			// test if update was successful
			Assert.AreEqual(1, Products_out.Count, "udpated result set");

			TUpdate_Return Product_out = (TUpdate_Return)Products_out.ToArray()[0];
			Assert.AreEqual(path + alias, Product_out.Path, "product path");
			Assert.AreEqual(true, Product_out.updated, "updated?");
		}