//-----------------------------------------------------------------------
// <auto-generated>
//   Ten kod zosta wygenerowany przez narzdzie.
//   Runtime Version:2.0.50215.44
//
//   Wprowadzanie zmian w tym pliku moe spowodowa nieprawidowe zachowanie
//   aplikacji, a zmiany zostan utracone po ponownym wygenerowaniu kodu.
// </auto-generated>
//-----------------------------------------------------------------------

using System;
using System.ComponentModel;
using System.Data;
using System.Diagnostics;
using System.Web.Services;
using System.Web.Services.Protocols;
using System.Xml.Serialization;

//
// Ten kod rdowy zosta wygenerowany automatycznie przez wsdl, Wersja=2.0.50215.44.
//
.
.
.
/// <remarks/>
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
[System.Web.Services.WebServiceBindingAttribute(Name="StockTickerSoap",
        Namespace="www.LibertyAssociates.com")]
[System.Xml.Serialization.XmlIncludeAttribute(typeof(object[]))]
public partial class StockTickerSoap :
   System.Web.Services.Protocols.SoapHttpClientProtocol {

    private System.Threading.SendOrPostCallback
        GetHistoryOperationCompleted;

    /// <remarks/>
    public StockTickerSoap() {
        this.Url = "http://localhost/stockticker/service.asmx";
    }

    /// <remarks/>
    public event GetHistoryCompletedEventHandler GetHistoryCompleted;
.
.
.
    [System.Web.Services.Protocols.SoapDocumentMethodAttribute(
            "www.LibertyAssociates.com/GetHistory",
            RequestNamespace="www.LibertyAssociates.com",
            ResponseNamespace="www.LibertyAssociates.com",
            Use=System.Web.Services.Description.SoapBindingUse.Literal,
            ParameterStyle=
                System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
    public Stock GetHistory(string StockSymbol) {
        object[] results = this.Invoke("GetHistory", new object[] {
                    StockSymbol});
        return ((Stock)(results[0]));
    }

    /// <remarks/>
    public System.IAsyncResult BeginGetHistory(string StockSymbol,
        System.AsyncCallback callback, object asyncState) {
        return this.BeginInvoke("GetHistory", new object[] {
                    StockSymbol}, callback, asyncState);
    }

    /// <remarks/>
    public Stock EndGetHistory(System.IAsyncResult asyncResult) {
        object[] results = this.EndInvoke(asyncResult);
        return ((Stock)(results[0]));
    }

    /// <remarks/>
    public void GetHistoryAsync(string StockSymbol) {
        this.GetHistoryAsync(StockSymbol, null);
    }

    /// <remarks/>
    public void GetHistoryAsync(string StockSymbol, object userState) {
        if ((this.GetHistoryOperationCompleted == null)) {
            this.GetHistoryOperationCompleted =
                new System.Threading.SendOrPostCallback(
                    this.OnGetHistoryOperationCompleted);
        }
        this.InvokeAsync("GetHistory", new object[] {
                    StockSymbol}, this.GetHistoryOperationCompleted,
                        userState);
    }

    private void OnGetHistoryOperationCompleted(object arg) {
        if ((this.GetHistoryCompleted != null)) {
            System.Web.Services.Protocols.InvokeCompletedEventArgs
                invokeArgs =
                 ((System.Web.Services.Protocols.InvokeCompletedEventArgs)
                   (arg));
            this.GetHistoryCompleted(this,
                new GetHistoryCompletedEventArgs(
                invokeArgs.Results, invokeArgs.Error,
                invokeArgs.Cancelled, invokeArgs.UserState));
        }
    }

    /// <remarks/>
    public new void CancelAsync(object userState) {
        base.CancelAsync(userState);
    }
}

/// <remarks/>
public delegate void GetHistoryCompletedEventHandler(object sender,
        GetHistoryCompletedEventArgs e);

/// <remarks/>
[System.SerializableAttribute()]
[System.Xml.Serialization.XmlTypeAttribute(Namespace=
    "www.LibertyAssociates.com")]
public partial class StockHistory {

    private System.DateTime tradeDateField;

    private double priceField;

    /// <remarks/>
    public System.DateTime TradeDate {
        get {
            return this.tradeDateField;
        }
        set {
            this.tradeDateField = value;
        }
    }

    /// <remarks/>
    public double Price {
        get {
            return this.priceField;
        }
        set {
            this.priceField = value;
        }
    }
}

/// <remarks/>
[System.SerializableAttribute()]
[System.Xml.Serialization.XmlTypeAttribute(
      Namespace="www.LibertyAssociates.com")]
public partial class Stock {

    private string stockSymbolField;

    private string stockNameField;

    private double priceField;

    private StockHistory[] historyField;

    /// <remarks/>
    public string StockSymbol {
        get {
            return this.stockSymbolField;
        }
        set {
            this.stockSymbolField = value;
        }
    }

    /// <remarks/>
    public string StockName {
        get {
            return this.stockNameField;
        }
        set {
            this.stockNameField = value;
        }
    }

    /// <remarks/>
    public double Price {
        get {
            return this.priceField;
        }
        set {
            this.priceField = value;
        }
    }

    /// <remarks/>
    public StockHistory[] History {
        get {
            return this.historyField;
        }
        set {
            this.historyField = value;
        }
    }
}
