コード例 #1
0
        /// <summary>
        /// Gets the customers.
        /// </summary>
        /// <returns></returns>
        public async Task <IEnumerable <Customer> > GetAllCustomers()
        {
            var service = DemoProxy.CustomerService();
            var result  = await service.GetAllCustomers();

            return(result);
        }
コード例 #2
0
        public async Task <int> CustomerCount()
        {
            var service = DemoProxy.CustomerService();
            var result  = await service.CustomerCount();

            return(result);
        }
コード例 #3
0
        /// <summary>
        /// Gets the customer.
        /// </summary>
        /// <param name="id">The identifier.</param>
        /// <returns></returns>
        public async Task <Customer> GetCustomer(int id)
        {
            var service = DemoProxy.CustomerService();
            var result  = await service.GetCustomer(id);

            return(result);
        }
コード例 #4
0
 public async Task RemoveCustomer(int customerId)
 {
     var service = DemoProxy.CustomerService();
     await service.RemoveCustomer(customerId);
 }
コード例 #5
0
 public async Task AddCustomer(Customer customer)
 {
     var service = DemoProxy.CustomerService();
     await service.AddCustomer(customer);
 }