コード例 #1
0
        public static string GenerateJsonQuery(QueryModel model)
        {
            var visitor = new LiteCoreQueryModelVisitor();

            visitor.VisitQueryModel(model);
            return(visitor.GetJsonQuery());
        }
コード例 #2
0
        public IEnumerable <T> ExecuteCollection <T>(QueryModel queryModel)
        {
            var visitor = new LiteCoreQueryModelVisitor();

            visitor.VisitQueryModel(queryModel);
            return(new[] { visitor.GetJsonQuery() } as IEnumerable <T>);
        }
コード例 #3
0
        public IEnumerable <T> ExecuteCollection <T>(QueryModel queryModel)
        {
            var visitor = new LiteCoreQueryModelVisitor();

            visitor.VisitQueryModel(queryModel);
            var query = visitor.GetJsonQuery();

            CreateQuery(query);
            while (MoveNext())
            {
                yield return(GetCurrent <T>(visitor.SelectResult));
            }
        }