Exemplo n.º 1
0
        public PaginatedElement <Telemetry> GetByPool(int poolId, IFilter <Telemetry> filter, int rowsPerPage, int pageNumber)
        {
            IEnumerable <Telemetry> telemetries = telemetryRepository.GetByPool(poolId, filter, rowsPerPage, pageNumber);
            int totalElementCount = telemetryRepository.CountByPool(poolId, filter);

            return(new PaginatedElement <Telemetry>
            {
                TotalElementCount = totalElementCount,
                Elements = telemetries,
                PageCount = RestApiHelper.GetPageCount(totalElementCount, rowsPerPage)
            });
        }