func New(s service.IOrderService, mdw map[string][]endpoint.Middleware) Endpoints {
	eps := Endpoints{
		CreateOrderEndpoint: MakeCreatedOrderEndpoint(s),
		ListOrderEndpoint:   MakeListOrderEndpoint(s),
	}

	// apply transport middlewares
	for _, m := range mdw["CreateOrder"] {
		eps.CreateOrderEndpoint = m(eps.CreateOrderEndpoint)
	}
	for _, m := range mdw["ListOrder"] {
		eps.ListOrderEndpoint = m(eps.ListOrderEndpoint)
	}

	return eps
}
// New returns a Endpoints struct that wraps the provided service, and wires in all of the
// expected endpoint middlewares
New returns a Endpoints struct that wraps the provided service, and wires in all of the
expected endpoint middlewares
// New returns a Endpoints struct that wraps the provided service and wires in all of the // expected endpoint middlewares
func New(s service.IOrderService, mdw map[string][]endpoint.Middleware) Endpoints {
	eps := Endpoints{
		CreateOrderEndpoint: MakeCreatedOrderEndpoint(s),
		ListOrderEndpoint:   MakeListOrderEndpoint(s),
	}
	for _, m := range mdw["CreateOrder"] {
		eps.CreateOrderEndpoint = m(eps.CreateOrderEndpoint)
	}
	for _, m := range mdw["ListOrder"] {
		eps.ListOrderEndpoint = m(eps.ListOrderEndpoint)
	}
	return eps
}
func New ( s service . IOrderService , mdw map [ string ] [ ] endpoint . Middleware ) Endpoints { eps := Endpoints { CreateOrderEndpoint : MakeCreatedOrderEndpoint ( s ) , ListOrderEndpoint : MakeListOrderEndpoint ( s ) , } for _ , m := range mdw [ " " ] { eps . CreateOrderEndpoint = m ( eps . CreateOrderEndpoint ) } for _ , m := range mdw [ " " ] { eps . ListOrderEndpoint = m ( eps . ListOrderEndpoint ) } return eps }
New returns a Endpoints struct that wraps the provided service, and wires in all of the
expected endpoint middlewares
New returns a Endpoints struct that wraps the provided service and wires in all of the expected endpoint middlewares
// apply transport middlewares