Restbucks.Service.Mappers.OrderRepresentationMapper.GetRepresentation C# (CSharp) Method

GetRepresentation() public method

public GetRepresentation ( Order order ) : OrderRepresentation
order Restbucks.Service.Domain.Order
return Restbucks.Service.Representations.OrderRepresentation
        public OrderRepresentation GetRepresentation(Order order)
        {
            return new OrderRepresentation
                       {
                           Cost = order.CalculateTotal(),
                           Items = order.Items.Select(_itemMapper.GetRepresentation).ToList(),
                           Location = order.Location,
                           Status = order.Status,
                       };
        }