Ejemplo n.º 1
0
        public async Task <ActionResult <IEnumerable <PongResponse> > > GetAll([FromServices] IPingPongStore pingPong)
        {
            var query = await pingPong.GetAsync();

            var result = query.ToArray();

            return(Ok(PongResponse.MapFrom(result)));
        }
Ejemplo n.º 2
0
        public async Task <IEnumerable <PongEntity> > Get([FromServices] IPingPongStore pingPong)
        {
            var pongs = await pingPong.GetAsync();

            return(PongEntity.MapFrom(pongs));
        }