/Chapter 5/Completed/MutualAuthenticationUsingCertificates/ProductsClient/Products.cs
https://bitbucket.org/dhirschl/wcf-4-step-by-step · C# · 303 lines · 247 code · 47 blank · 9 comment · 0 complexity · e5a9584d3c9baabd8985019b5a7b393b MD5 · raw file
- //------------------------------------------------------------------------------
- // <auto-generated>
- // This code was generated by a tool.
- // Runtime Version:4.0.30319.1
- //
- // Changes to this file may cause incorrect behavior and will be lost if
- // the code is regenerated.
- // </auto-generated>
- //------------------------------------------------------------------------------
- namespace ProductsClient.ProductsService
- {
- using System.Runtime.Serialization;
-
-
- [System.Diagnostics.DebuggerStepThroughAttribute()]
- [System.CodeDom.Compiler.GeneratedCodeAttribute("System.Runtime.Serialization", "4.0.0.0")]
- [System.Runtime.Serialization.DataContractAttribute(Name="ProductData", Namespace="http://schemas.datacontract.org/2004/07/Products")]
- public partial class ProductData : object, System.Runtime.Serialization.IExtensibleDataObject
- {
-
- private System.Runtime.Serialization.ExtensionDataObject extensionDataField;
-
- private string ColorField;
-
- private decimal ListPriceField;
-
- private string NameField;
-
- private string ProductNumberField;
-
- public System.Runtime.Serialization.ExtensionDataObject ExtensionData
- {
- get
- {
- return this.extensionDataField;
- }
- set
- {
- this.extensionDataField = value;
- }
- }
-
- [System.Runtime.Serialization.DataMemberAttribute()]
- public string Color
- {
- get
- {
- return this.ColorField;
- }
- set
- {
- this.ColorField = value;
- }
- }
-
- [System.Runtime.Serialization.DataMemberAttribute()]
- public decimal ListPrice
- {
- get
- {
- return this.ListPriceField;
- }
- set
- {
- this.ListPriceField = value;
- }
- }
-
- [System.Runtime.Serialization.DataMemberAttribute()]
- public string Name
- {
- get
- {
- return this.NameField;
- }
- set
- {
- this.NameField = value;
- }
- }
-
- [System.Runtime.Serialization.DataMemberAttribute()]
- public string ProductNumber
- {
- get
- {
- return this.ProductNumberField;
- }
- set
- {
- this.ProductNumberField = value;
- }
- }
- }
-
- [System.Diagnostics.DebuggerStepThroughAttribute()]
- [System.CodeDom.Compiler.GeneratedCodeAttribute("System.Runtime.Serialization", "4.0.0.0")]
- [System.Runtime.Serialization.DataContractAttribute(Name="DatabaseFault", Namespace="http://schemas.datacontract.org/2004/07/Products")]
- public partial class DatabaseFault : object, System.Runtime.Serialization.IExtensibleDataObject
- {
-
- private System.Runtime.Serialization.ExtensionDataObject extensionDataField;
-
- private string DbMessageField;
-
- private string DbOperationField;
-
- private string DbReasonField;
-
- public System.Runtime.Serialization.ExtensionDataObject ExtensionData
- {
- get
- {
- return this.extensionDataField;
- }
- set
- {
- this.extensionDataField = value;
- }
- }
-
- [System.Runtime.Serialization.DataMemberAttribute()]
- public string DbMessage
- {
- get
- {
- return this.DbMessageField;
- }
- set
- {
- this.DbMessageField = value;
- }
- }
-
- [System.Runtime.Serialization.DataMemberAttribute()]
- public string DbOperation
- {
- get
- {
- return this.DbOperationField;
- }
- set
- {
- this.DbOperationField = value;
- }
- }
-
- [System.Runtime.Serialization.DataMemberAttribute()]
- public string DbReason
- {
- get
- {
- return this.DbReasonField;
- }
- set
- {
- this.DbReasonField = value;
- }
- }
- }
-
- [System.Diagnostics.DebuggerStepThroughAttribute()]
- [System.CodeDom.Compiler.GeneratedCodeAttribute("System.Runtime.Serialization", "4.0.0.0")]
- [System.Runtime.Serialization.DataContractAttribute(Name="SystemFault", Namespace="http://schemas.datacontract.org/2004/07/Products")]
- public partial class SystemFault : object, System.Runtime.Serialization.IExtensibleDataObject
- {
-
- private System.Runtime.Serialization.ExtensionDataObject extensionDataField;
-
- private string SystemMessageField;
-
- private string SystemOperationField;
-
- private string SystemReasonField;
-
- public System.Runtime.Serialization.ExtensionDataObject ExtensionData
- {
- get
- {
- return this.extensionDataField;
- }
- set
- {
- this.extensionDataField = value;
- }
- }
-
- [System.Runtime.Serialization.DataMemberAttribute()]
- public string SystemMessage
- {
- get
- {
- return this.SystemMessageField;
- }
- set
- {
- this.SystemMessageField = value;
- }
- }
-
- [System.Runtime.Serialization.DataMemberAttribute()]
- public string SystemOperation
- {
- get
- {
- return this.SystemOperationField;
- }
- set
- {
- this.SystemOperationField = value;
- }
- }
-
- [System.Runtime.Serialization.DataMemberAttribute()]
- public string SystemReason
- {
- get
- {
- return this.SystemReasonField;
- }
- set
- {
- this.SystemReasonField = value;
- }
- }
- }
-
- [System.CodeDom.Compiler.GeneratedCodeAttribute("System.ServiceModel", "4.0.0.0")]
- [System.ServiceModel.ServiceContractAttribute(ConfigurationName="ProductsClient.ProductsService.IProductsService")]
- public interface IProductsService
- {
-
- [System.ServiceModel.OperationContractAttribute(Action="http://tempuri.org/IProductsService/ListProducts", ReplyAction="http://tempuri.org/IProductsService/ListProductsResponse")]
- [System.ServiceModel.FaultContractAttribute(typeof(ProductsClient.ProductsService.DatabaseFault), Action="http://tempuri.org/IProductsService/ListProductsDatabaseFaultFault", Name="DatabaseFault", Namespace="http://schemas.datacontract.org/2004/07/Products")]
- [System.ServiceModel.FaultContractAttribute(typeof(ProductsClient.ProductsService.SystemFault), Action="http://tempuri.org/IProductsService/ListProductsSystemFaultFault", Name="SystemFault", Namespace="http://schemas.datacontract.org/2004/07/Products")]
- string[] ListProducts();
-
- [System.ServiceModel.OperationContractAttribute(Action="http://tempuri.org/IProductsService/GetProduct", ReplyAction="http://tempuri.org/IProductsService/GetProductResponse")]
- ProductsClient.ProductsService.ProductData GetProduct(string productNumber);
-
- [System.ServiceModel.OperationContractAttribute(Action="http://tempuri.org/IProductsService/CurrentStockLevel", ReplyAction="http://tempuri.org/IProductsService/CurrentStockLevelResponse")]
- int CurrentStockLevel(string productNumber);
-
- [System.ServiceModel.OperationContractAttribute(Action="http://tempuri.org/IProductsService/ChangeStockLevel", ReplyAction="http://tempuri.org/IProductsService/ChangeStockLevelResponse")]
- bool ChangeStockLevel(string productNumber, short newStockLevel, string shelf, int bin);
- }
-
- [System.CodeDom.Compiler.GeneratedCodeAttribute("System.ServiceModel", "4.0.0.0")]
- public interface IProductsServiceChannel : ProductsClient.ProductsService.IProductsService, System.ServiceModel.IClientChannel
- {
- }
-
- [System.Diagnostics.DebuggerStepThroughAttribute()]
- [System.CodeDom.Compiler.GeneratedCodeAttribute("System.ServiceModel", "4.0.0.0")]
- public partial class ProductsServiceClient : System.ServiceModel.ClientBase<ProductsClient.ProductsService.IProductsService>, ProductsClient.ProductsService.IProductsService
- {
-
- public ProductsServiceClient()
- {
- }
-
- public ProductsServiceClient(string endpointConfigurationName) :
- base(endpointConfigurationName)
- {
- }
-
- public ProductsServiceClient(string endpointConfigurationName, string remoteAddress) :
- base(endpointConfigurationName, remoteAddress)
- {
- }
-
- public ProductsServiceClient(string endpointConfigurationName, System.ServiceModel.EndpointAddress remoteAddress) :
- base(endpointConfigurationName, remoteAddress)
- {
- }
-
- public ProductsServiceClient(System.ServiceModel.Channels.Binding binding, System.ServiceModel.EndpointAddress remoteAddress) :
- base(binding, remoteAddress)
- {
- }
-
- public string[] ListProducts()
- {
- return base.Channel.ListProducts();
- }
-
- public ProductsClient.ProductsService.ProductData GetProduct(string productNumber)
- {
- return base.Channel.GetProduct(productNumber);
- }
-
- public int CurrentStockLevel(string productNumber)
- {
- return base.Channel.CurrentStockLevel(productNumber);
- }
-
- public bool ChangeStockLevel(string productNumber, short newStockLevel, string shelf, int bin)
- {
- return base.Channel.ChangeStockLevel(productNumber, newStockLevel, shelf, bin);
- }
- }
- }