Esempio n. 1
0
        /// <summary>
        /// DatasByTableQuery
        /// </summary>
        /// <param name="tableQuery"></param>
        /// <returns></returns>
        public IEnumerable <T> DatasByTableQuery(TableQuery <T> tableQuery)
        {
            var res = new ConcurrentList <T>();

            TableContinuationToken continuationToken = null;

            do
            {
                var page = CTable.ExecuteQuerySegmentedAsync(tableQuery, continuationToken).Result;
                continuationToken = page.ContinuationToken;
                if (page.Results != null)
                {
                    foreach (var obj in page.Results)
                    {
                        res.Add(obj);
                    }
                }
            }while (continuationToken != null);

            return(res);
        }