131 lines
5.4 KiB
C#
131 lines
5.4 KiB
C#
using System;
|
|
using System.Diagnostics;
|
|
using System.Web.Services;
|
|
using System.ComponentModel;
|
|
using System.Web.Services.Protocols;
|
|
using System.Xml.Serialization;
|
|
using EAS.Distributed;
|
|
|
|
namespace EAS.Distributed
|
|
{
|
|
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.Web.Services", "2.0.50727.4927")]
|
|
[System.Diagnostics.DebuggerStepThroughAttribute()]
|
|
[System.ComponentModel.DesignerCategoryAttribute("code")]
|
|
[System.Web.Services.WebServiceBindingAttribute(Name = "SmartUpdateServiceSoap", Namespace = "http://SmartEAS.net/webservices/")]
|
|
partial class Service_Proxy : System.Web.Services.Protocols.SoapHttpClientProtocol, IUpdateService
|
|
{
|
|
private bool useDefaultCredentialsSetExplicitly;
|
|
|
|
/// <remarks/>
|
|
public Service_Proxy()
|
|
{
|
|
this.Url = string.Empty;
|
|
if ((this.IsLocalFileSystemWebService(this.Url) == true))
|
|
{
|
|
this.UseDefaultCredentials = true;
|
|
this.useDefaultCredentialsSetExplicitly = false;
|
|
}
|
|
else
|
|
{
|
|
this.useDefaultCredentialsSetExplicitly = true;
|
|
}
|
|
}
|
|
|
|
public Service_Proxy(string url)
|
|
{
|
|
this.Url = url;
|
|
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/>
|
|
[System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://SmartEAS.net/webservices/GetSmartUpdateTime", RequestNamespace = "http://SmartEAS.net/webservices/", ResponseNamespace = "http://SmartEAS.net/webservices/", Use = System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle = System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
|
|
public System.DateTime GetSmartUpdateTime()
|
|
{
|
|
object[] results = this.Invoke("GetSmartUpdateTime", new object[0]);
|
|
return ((System.DateTime)(results[0]));
|
|
}
|
|
|
|
/// <remarks/>
|
|
[System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://SmartEAS.net/webservices/GetSmartFileCount", RequestNamespace = "http://SmartEAS.net/webservices/", ResponseNamespace = "http://SmartEAS.net/webservices/", Use = System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle = System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
|
|
public System.Int32 GetSmartFileCount(DateTime lastTime)
|
|
{
|
|
object[] results = this.Invoke("GetSmartFileCount", new object[] {
|
|
lastTime});
|
|
return ((System.Int32)(results[0]));
|
|
}
|
|
|
|
/// <remarks/>
|
|
[System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://SmartEAS.net/webservices/GetSmartUpdateConfig", RequestNamespace = "http://SmartEAS.net/webservices/", ResponseNamespace = "http://SmartEAS.net/webservices/", Use = System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle = System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
|
|
public string GetSmartUpdateConfig()
|
|
{
|
|
object[] results = this.Invoke("GetSmartUpdateConfig", new object[0]);
|
|
return ((string)(results[0]));
|
|
}
|
|
|
|
/// <remarks/>
|
|
[System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://SmartEAS.net/webservices/DownloadSmartFile", RequestNamespace = "http://SmartEAS.net/webservices/", ResponseNamespace = "http://SmartEAS.net/webservices/", Use = System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle = System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
|
|
[return: System.Xml.Serialization.XmlElementAttribute(DataType = "base64Binary")]
|
|
public byte[] DownloadSmartFile(string smartFileName)
|
|
{
|
|
object[] results = this.Invoke("DownloadSmartFile", new object[] {
|
|
smartFileName});
|
|
return ((byte[])(results[0]));
|
|
}
|
|
|
|
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;
|
|
}
|
|
}
|
|
}
|