Ejemplo n.º 1
0
        /// <summary>
        /// Creates a new <see cref="QueryModelVisitor"/>, and returns the result of running <see cref="QueryModelVisitor.VisitAndGenerateQueryDescription"/> on the
        /// supplied <paramref name="queryModel"/>.
        /// </summary>
        /// <param name="queryModel">The query model.</param>
        /// <param name="structureBinder">The structure binder.</param>
        /// <param name="treeVisitor">The tree visitor.</param>
        /// <returns></returns>
        /// <remarks></remarks>
        public static QueryDescription FromQueryModel(Remotion.Linq.QueryModel queryModel, AbstractQueryStructureBinder structureBinder, AbstractExpressionTreeVisitor treeVisitor)
        {
            var elrmv = new QueryModelVisitor(structureBinder, treeVisitor);

            return(elrmv.VisitAndGenerateQueryDescription(queryModel));
        }
Ejemplo n.º 2
0
 /// <summary>
 /// Initializes a new instance of the <see cref="QueryModelVisitor"/> class.
 /// </summary>
 /// <param name="structureBinder">The structure binder.</param>
 /// <param name="treeVisitor">The tree visitor.</param>
 /// <remarks></remarks>
 public QueryModelVisitor(AbstractQueryStructureBinder structureBinder, AbstractExpressionTreeVisitor treeVisitor)
 {
     _structureBinder = structureBinder;
     _treeVisitor     = treeVisitor;
 }