Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- //------------------------------------------------------------------------------
- // <auto-generated>
- // This code was generated by a tool.
- // Runtime Version:4.0.30319.42000
- //
- // Changes to this file may cause incorrect behavior and will be lost if
- // the code is regenerated.
- // </auto-generated>
- //------------------------------------------------------------------------------
- //
- // This source code was auto-generated by Microsoft.VSDesigner, Version 4.0.30319.42000.
- //
- #pragma warning disable 1591
- namespace AndroidWebService.selling {
- using System;
- using System.Web.Services;
- using System.Diagnostics;
- using System.Web.Services.Protocols;
- using System.Xml.Serialization;
- using System.ComponentModel;
- /// <remarks/>
- [System.CodeDom.Compiler.GeneratedCodeAttribute("System.Web.Services", "4.6.1055.0")]
- [System.Diagnostics.DebuggerStepThroughAttribute()]
- [System.ComponentModel.DesignerCategoryAttribute("code")]
- [System.Web.Services.WebServiceBindingAttribute(Name="WebServiceDBSoap", Namespace="http://tempuri.org/")]
- public partial class WebServiceDB : System.Web.Services.Protocols.SoapHttpClientProtocol {
- private System.Threading.SendOrPostCallback RegisterOperationCompleted;
- private System.Threading.SendOrPostCallback LoginOperationCompleted;
- private bool useDefaultCredentialsSetExplicitly;
- /// <remarks/>
- public WebServiceDB() {
- this.Url = "http://selling.alruabye.net/WebServiceDB.asmx";
- if ((this.IsLocalFileSystemWebService(this.Url) == true)) {
- this.UseDefaultCredentials = true;
- this.useDefaultCredentialsSetExplicitly = false;
- }
- else {
- this.useDefaultCredentialsSetExplicitly = true;
- }
- }
- public new string Url {
- get {
- return base.Url;
- }
- set {
- if ((((this.IsLocalFileSystemWebService(base.Url) == true)
- && (this.useDefaultCredentialsSetExplicitly == false))
- && (this.IsLocalFileSystemWebService(value) == false))) {
- base.UseDefaultCredentials = false;
- }
- base.Url = value;
- }
- }
- public new bool UseDefaultCredentials {
- get {
- return base.UseDefaultCredentials;
- }
- set {
- base.UseDefaultCredentials = value;
- this.useDefaultCredentialsSetExplicitly = true;
- }
- }
- /// <remarks/>
- public event RegisterCompletedEventHandler RegisterCompleted;
- /// <remarks/>
- public event LoginCompletedEventHandler LoginCompleted;
- /// <remarks/>
- [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/Register", RequestNamespace="http://tempuri.org/", ResponseNamespace="http://tempuri.org/", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
- public ReturnData Register(string UserName, string Password, string Email, string PhoneNumber, string Logtit, string Latitle) {
- object[] results = this.Invoke("Register", new object[] {
- UserName,
- Password,
- Email,
- PhoneNumber,
- Logtit,
- Latitle});
- return ((ReturnData)(results[0]));
- }
- /// <remarks/>
- public void RegisterAsync(string UserName, string Password, string Email, string PhoneNumber, string Logtit, string Latitle) {
- this.RegisterAsync(UserName, Password, Email, PhoneNumber, Logtit, Latitle, null);
- }
- /// <remarks/>
- public void RegisterAsync(string UserName, string Password, string Email, string PhoneNumber, string Logtit, string Latitle, object userState) {
- if ((this.RegisterOperationCompleted == null)) {
- this.RegisterOperationCompleted = new System.Threading.SendOrPostCallback(this.OnRegisterOperationCompleted);
- }
- this.InvokeAsync("Register", new object[] {
- UserName,
- Password,
- Email,
- PhoneNumber,
- Logtit,
- Latitle}, this.RegisterOperationCompleted, userState);
- }
- private void OnRegisterOperationCompleted(object arg) {
- if ((this.RegisterCompleted != null)) {
- System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg));
- this.RegisterCompleted(this, new RegisterCompletedEventArgs(invokeArgs.Results, invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
- }
- }
- /// <remarks/>
- [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/Login", RequestNamespace="http://tempuri.org/", ResponseNamespace="http://tempuri.org/", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
- public ReturnData Login(string UserName, string Password) {
- object[] results = this.Invoke("Login", new object[] {
- UserName,
- Password});
- return ((ReturnData)(results[0]));
- }
- /// <remarks/>
- public void LoginAsync(string UserName, string Password) {
- this.LoginAsync(UserName, Password, null);
- }
- /// <remarks/>
- public void LoginAsync(string UserName, string Password, object userState) {
- if ((this.LoginOperationCompleted == null)) {
- this.LoginOperationCompleted = new System.Threading.SendOrPostCallback(this.OnLoginOperationCompleted);
- }
- this.InvokeAsync("Login", new object[] {
- UserName,
- Password}, this.LoginOperationCompleted, userState);
- }
- private void OnLoginOperationCompleted(object arg) {
- if ((this.LoginCompleted != null)) {
- System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg));
- this.LoginCompleted(this, new LoginCompletedEventArgs(invokeArgs.Results, invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
- }
- }
- /// <remarks/>
- public new void CancelAsync(object userState) {
- base.CancelAsync(userState);
- }
- private bool IsLocalFileSystemWebService(string url) {
- if (((url == null)
- || (url == string.Empty))) {
- return false;
- }
- System.Uri wsUri = new System.Uri(url);
- if (((wsUri.Port >= 1024)
- && (string.Compare(wsUri.Host, "localHost", System.StringComparison.OrdinalIgnoreCase) == 0))) {
- return true;
- }
- return false;
- }
- }
- /// <remarks/>
- [System.CodeDom.Compiler.GeneratedCodeAttribute("System.Xml", "4.6.1064.2")]
- [System.SerializableAttribute()]
- [System.Diagnostics.DebuggerStepThroughAttribute()]
- [System.ComponentModel.DesignerCategoryAttribute("code")]
- [System.Xml.Serialization.XmlTypeAttribute(Namespace="http://tempuri.org/")]
- public partial class ReturnData {
- private string messageField;
- private int userIDField;
- /// <remarks/>
- public string Message {
- get {
- return this.messageField;
- }
- set {
- this.messageField = value;
- }
- }
- /// <remarks/>
- public int UserID {
- get {
- return this.userIDField;
- }
- set {
- this.userIDField = value;
- }
- }
- }
- /// <remarks/>
- [System.CodeDom.Compiler.GeneratedCodeAttribute("System.Web.Services", "4.6.1055.0")]
- public delegate void RegisterCompletedEventHandler(object sender, RegisterCompletedEventArgs e);
- /// <remarks/>
- [System.CodeDom.Compiler.GeneratedCodeAttribute("System.Web.Services", "4.6.1055.0")]
- [System.Diagnostics.DebuggerStepThroughAttribute()]
- [System.ComponentModel.DesignerCategoryAttribute("code")]
- public partial class RegisterCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
- private object[] results;
- internal RegisterCompletedEventArgs(object[] results, System.Exception exception, bool cancelled, object userState) :
- base(exception, cancelled, userState) {
- this.results = results;
- }
- /// <remarks/>
- public ReturnData Result {
- get {
- this.RaiseExceptionIfNecessary();
- return ((ReturnData)(this.results[0]));
- }
- }
- }
- /// <remarks/>
- [System.CodeDom.Compiler.GeneratedCodeAttribute("System.Web.Services", "4.6.1055.0")]
- public delegate void LoginCompletedEventHandler(object sender, LoginCompletedEventArgs e);
- /// <remarks/>
- [System.CodeDom.Compiler.GeneratedCodeAttribute("System.Web.Services", "4.6.1055.0")]
- [System.Diagnostics.DebuggerStepThroughAttribute()]
- [System.ComponentModel.DesignerCategoryAttribute("code")]
- public partial class LoginCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
- private object[] results;
- internal LoginCompletedEventArgs(object[] results, System.Exception exception, bool cancelled, object userState) :
- base(exception, cancelled, userState) {
- this.results = results;
- }
- /// <remarks/>
- public ReturnData Result {
- get {
- this.RaiseExceptionIfNecessary();
- return ((ReturnData)(this.results[0]));
- }
- }
- }
- }
- #pragma warning restore 1591
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement