示例#1
0
 /// <summary>
 /// Transforms both sides of the Join using the given Optimiser
 /// </summary>
 /// <param name="optimiser">Optimser</param>
 /// <returns></returns>
 public ISparqlAlgebra Transform(IAlgebraOptimiser optimiser)
 {
     return(new AskUnion(optimiser.Optimise(this._lhs), optimiser.Optimise(this._rhs)));
 }
示例#2
0
 /// <summary>
 /// Transforms the RHS of the Join using the given Optimiser
 /// </summary>
 /// <param name="optimiser">Optimser</param>
 /// <returns></returns>
 public ISparqlAlgebra TransformRhs(IAlgebraOptimiser optimiser)
 {
     return(new ExistsJoin(_lhs, optimiser.Optimise(_rhs), _mustExist));
 }
示例#3
0
 /// <summary>
 /// Transforms the LHS of the Join using the given Optimiser
 /// </summary>
 /// <param name="optimiser">Optimser</param>
 /// <returns></returns>
 public ISparqlAlgebra TransformLhs(IAlgebraOptimiser optimiser)
 {
     return(new Union(optimiser.Optimise(_lhs), _rhs));
 }
示例#4
0
文件: Project.cs 项目: jmahmud/RDFer
 /// <summary>
 /// Transforms the Inner Algebra using the given Optimiser
 /// </summary>
 /// <param name="optimiser">Optimiser</param>
 /// <returns></returns>
 public ISparqlAlgebra Transform(IAlgebraOptimiser optimiser)
 {
     return new Select(optimiser.Optimise(this._pattern), this._variables);
 }
示例#5
0
文件: GroupBy.cs 项目: jmahmud/RDFer
 /// <summary>
 /// Transforms the Inner Algebra using the given Optimiser
 /// </summary>
 /// <param name="optimiser">Optimiser</param>
 /// <returns></returns>
 public ISparqlAlgebra Transform(IAlgebraOptimiser optimiser)
 {
     return new GroupBy(optimiser.Optimise(this._pattern), this._grouping);
 }
示例#6
0
 /// <summary>
 /// Transforms the RHS of the Join using the given Optimiser
 /// </summary>
 /// <param name="optimiser">Optimser</param>
 /// <returns></returns>
 public ISparqlAlgebra TransformRhs(IAlgebraOptimiser optimiser)
 {
     if (optimiser is IExpressionTransformer)
     {
         return new LeftJoin(this._lhs, optimiser.Optimise(this._rhs), new UnaryExpressionFilter(((IExpressionTransformer)optimiser).Transform(this._filter.Expression)));
     }
     else
     {
         return new LeftJoin(this._lhs, optimiser.Optimise(this._rhs), this._filter);
     }
 }
示例#7
0
文件: Filter.cs 项目: jmahmud/RDFer
 /// <summary>
 /// Transforms the Inner Algebra using the given Optimiser
 /// </summary>
 /// <param name="optimiser">Optimiser</param>
 /// <returns></returns>
 public ISparqlAlgebra Transform(IAlgebraOptimiser optimiser)
 {
     if (optimiser is IExpressionTransformer)
     {
         return new Filter(optimiser.Optimise(this._pattern), new UnaryExpressionFilter(((IExpressionTransformer)optimiser).Transform(this._filter.Expression)));
     }
     else
     {
         return new Filter(optimiser.Optimise(this._pattern), this._filter);
     }
 }
示例#8
0
 /// <summary>
 /// Transforms the RHS algebra only with the given optimiser.
 /// </summary>
 /// <param name="optimiser">Algebra Optimiser.</param>
 /// <returns></returns>
 public ISparqlAlgebra TransformRhs(IAlgebraOptimiser optimiser)
 {
     return(new FilteredProduct(_lhs, optimiser.Optimise(_rhs), _expr));
 }
示例#9
0
文件: OrderBy.cs 项目: jmahmud/RDFer
 /// <summary>
 /// Transforms the Inner Algebra using the given Optimiser
 /// </summary>
 /// <param name="optimiser">Optimiser</param>
 /// <returns></returns>
 public ISparqlAlgebra Transform(IAlgebraOptimiser optimiser)
 {
     return new OrderBy(optimiser.Optimise(this._pattern), this._ordering);
 }
示例#10
0
 /// <summary>
 /// Transforms the LHS of the Join using the given Optimiser
 /// </summary>
 /// <param name="optimiser">Optimser</param>
 /// <returns></returns>
 public ISparqlAlgebra TransformLhs(IAlgebraOptimiser optimiser)
 {
     return(new ExistsJoin(optimiser.Optimise(this._lhs), this._rhs, this._mustExist));
 }
示例#11
0
 /// <summary>
 /// Transforms the Inner Algebra using the given Optimiser
 /// </summary>
 /// <param name="optimiser">Optimiser</param>
 /// <returns></returns>
 public override ISparqlAlgebra Transform(IAlgebraOptimiser optimiser)
 {
     return(new FullTextMatch(this.SearchProvider, optimiser.Optimise(this.InnerAlgebra), this.MatchItem, this.ScoreItem, this.SearchTerm, this.Limit, this.ScoreThreshold));
 }
示例#12
0
文件: Slice.cs 项目: jmahmud/RDFer
 /// <summary>
 /// Transforms the Inner Algebra using the given Optimiser
 /// </summary>
 /// <param name="optimiser">Optimiser</param>
 /// <returns></returns>
 public ISparqlAlgebra Transform(IAlgebraOptimiser optimiser)
 {
     return new Slice(optimiser.Optimise(this._pattern), this._limit, this._offset);
 }
示例#13
0
文件: Having.cs 项目: jmahmud/RDFer
 /// <summary>
 /// Transforms the Inner Algebra using the given Optimiser
 /// </summary>
 /// <param name="optimiser">Optimiser</param>
 /// <returns></returns>
 public ISparqlAlgebra Transform(IAlgebraOptimiser optimiser)
 {
     return new Having(optimiser.Optimise(this._pattern), this._having);
 }
示例#14
0
 /// <summary>
 /// Transforms the RHS of the Join using the given Optimiser.
 /// </summary>
 /// <param name="optimiser">Optimser.</param>
 /// <returns></returns>
 public ISparqlAlgebra TransformRhs(IAlgebraOptimiser optimiser)
 {
     return(new ParallelJoin(_lhs, optimiser.Optimise(_rhs)));
 }
示例#15
0
 /// <summary>
 /// Transforms the Inner Algebra using the given Optimiser
 /// </summary>
 /// <param name="optimiser">Optimiser</param>
 /// <returns></returns>
 public ISparqlAlgebra Transform(IAlgebraOptimiser optimiser)
 {
     return(new Graph(optimiser.Optimise(this._pattern), this._graphSpecifier));
 }
示例#16
0
 /// <summary>
 /// Transforms the Inner Algebra using the given Optimiser
 /// </summary>
 /// <param name="optimiser">Optimiser</param>
 /// <returns></returns>
 public override ISparqlAlgebra Transform(IAlgebraOptimiser optimiser)
 {
     return new FullTextMatch(this.SearchProvider, optimiser.Optimise(this.InnerAlgebra), this.MatchItem, this.ScoreItem, this.SearchTerm, this.Limit, this.ScoreThreshold);
 }
示例#17
0
 /// <summary>
 /// Transforms the RHS of the Join using the given Optimiser.
 /// </summary>
 /// <param name="optimiser">Optimser.</param>
 /// <returns></returns>
 public ISparqlAlgebra TransformRhs(IAlgebraOptimiser optimiser)
 {
     return(new LazyUnion(_lhs, optimiser.Optimise(_rhs)));
 }
示例#18
0
 /// <summary>
 /// Transforms the Inner Algebra using the given Optimiser
 /// </summary>
 /// <param name="optimiser">Optimiser</param>
 /// <returns></returns>
 public override ISparqlAlgebra Transform(IAlgebraOptimiser optimiser)
 {
     if (optimiser is IExpressionTransformer)
     {
         return new IdentityFilter(optimiser.Optimise(this.InnerAlgebra), this.RestrictionVariable, (ConstantTerm)((IExpressionTransformer)optimiser).Transform(this.RestrictionValue));
     }
     else
     {
         return new IdentityFilter(optimiser.Optimise(this.InnerAlgebra), this.RestrictionVariable, this.RestrictionValue);
     }
 }
示例#19
0
 /// <summary>
 /// Transforms the RHS of the Join using the given Optimiser
 /// </summary>
 /// <param name="optimiser">Optimser</param>
 /// <returns></returns>
 public ISparqlAlgebra TransformRhs(IAlgebraOptimiser optimiser)
 {
     return new Union(this._lhs, optimiser.Optimise(this._rhs));
 }
示例#20
0
 /// <summary>
 /// Transforms the LHS of the Join using the given optimiser.
 /// </summary>
 /// <param name="optimiser">optimser.</param>
 /// <returns></returns>
 public ISparqlAlgebra TransformLhs(IAlgebraOptimiser optimiser)
 {
     return(new ParallelUnion(optimiser.Optimise(Lhs), Rhs));
 }
示例#21
0
 /// <summary>
 /// Transforms the LHS of the Join using the given Optimiser
 /// </summary>
 /// <param name="optimiser">Optimser</param>
 /// <returns></returns>
 public ISparqlAlgebra TransformLhs(IAlgebraOptimiser optimiser)
 {
     return(new LazyUnion(optimiser.Optimise(this._lhs), this._rhs));
 }
示例#22
0
 /// <summary>
 /// Transforms the Inner Algebra using the given Optimiser.
 /// </summary>
 /// <param name="optimiser">Optimiser.</param>
 /// <returns></returns>
 public ISparqlAlgebra Transform(IAlgebraOptimiser optimiser)
 {
     return(new Slice(optimiser.Optimise(_pattern), _limit, _offset));
 }
示例#23
0
 /// <summary>
 /// Transforms the Inner Algebra using the given Optimiser.
 /// </summary>
 /// <param name="optimiser">Optimiser.</param>
 /// <returns></returns>
 public ISparqlAlgebra Transform(IAlgebraOptimiser optimiser)
 {
     return(new Distinct(optimiser.Optimise(_pattern)));
 }
示例#24
0
 /// <summary>
 /// Transforms the LHS algebra only with the given optimiser
 /// </summary>
 /// <param name="optimiser">Algebra Optimiser</param>
 /// <returns></returns>
 public ISparqlAlgebra TransformLhs(IAlgebraOptimiser optimiser)
 {
     return(new FilteredProduct(optimiser.Optimise(this._lhs), this._rhs, this._expr));
 }
示例#25
0
 /// <summary>
 /// Transforms the Inner Algebra using the given Optimiser
 /// </summary>
 /// <param name="optimiser">Optimiser</param>
 /// <returns></returns>
 public ISparqlAlgebra Transform(IAlgebraOptimiser optimiser)
 {
     return(new OrderBy(optimiser.Optimise(this._pattern), this._ordering));
 }
示例#26
0
 /// <summary>
 /// Transforms this algebra with the given optimiser.
 /// </summary>
 /// <param name="optimiser">Optimiser.</param>
 /// <returns></returns>
 public ISparqlAlgebra Transform(IAlgebraOptimiser optimiser)
 {
     return(new PropertyFunction(optimiser.Optimise(_algebra), _function));
 }
示例#27
0
 /// <summary>
 /// Transforms both sides of the Join using the given Optimiser
 /// </summary>
 /// <param name="optimiser">Optimser</param>
 /// <returns></returns>
 public ISparqlAlgebra Transform(IAlgebraOptimiser optimiser)
 {
     return(new Join(optimiser.Optimise(_lhs), optimiser.Optimise(_rhs)));
 }
示例#28
0
文件: Distinct.cs 项目: jmahmud/RDFer
 /// <summary>
 /// Transforms the Inner Algebra using the given Optimiser
 /// </summary>
 /// <param name="optimiser">Optimiser</param>
 /// <returns></returns>
 public ISparqlAlgebra Transform(IAlgebraOptimiser optimiser)
 {
     return new Reduced(optimiser.Optimise(this._pattern));
 }
示例#29
0
 /// <summary>
 /// Transforms the Inner Algebra using the given Optimiser
 /// </summary>
 /// <param name="optimiser">Optimiser</param>
 /// <returns></returns>
 public ISparqlAlgebra Transform(IAlgebraOptimiser optimiser)
 {
     return(new Having(optimiser.Optimise(this._pattern), this._having));
 }
 /// <summary>
 /// Transforms the LHS of the Join using the given Optimiser
 /// </summary>
 /// <param name="optimiser">Optimser</param>
 /// <returns></returns>
 public ISparqlAlgebra TransformLhs(IAlgebraOptimiser optimiser)
 {
     return(new ParallelJoin(optimiser.Optimise(this._lhs), this._rhs));
 }
 /// <summary>
 /// Transforms both sides of the Join using the given Optimiser
 /// </summary>
 /// <param name="optimiser">Optimser</param>
 /// <returns></returns>
 public ISparqlAlgebra Transform(IAlgebraOptimiser optimiser)
 {
     return new ParallelJoin(optimiser.Optimise(this._lhs), optimiser.Optimise(this._rhs));
 }
示例#32
0
 /// <summary>
 /// Transforms the Inner Algebra using the given Optimiser
 /// </summary>
 /// <param name="optimiser">Optimiser</param>
 /// <returns></returns>
 public ISparqlAlgebra Transform(IAlgebraOptimiser optimiser)
 {
     return(new GroupBy(optimiser.Optimise(this._pattern), this._grouping, this._aggregates));
 }
示例#33
0
 /// <summary>
 /// Transforms the Inner Algebra using the given Optimiser
 /// </summary>
 /// <param name="optimiser">Optimiser</param>
 /// <returns></returns>
 public ISparqlAlgebra Transform(IAlgebraOptimiser optimiser)
 {
     return(new Reduced(optimiser.Optimise(this._pattern)));
 }
示例#34
0
文件: Graph.cs 项目: jmahmud/RDFer
 /// <summary>
 /// Transforms the Inner Algebra using the given Optimiser
 /// </summary>
 /// <param name="optimiser">Optimiser</param>
 /// <returns></returns>
 public ISparqlAlgebra Transform(IAlgebraOptimiser optimiser)
 {
     return new Graph(optimiser.Optimise(this._pattern), this._graphSpecifier);
 }
示例#35
0
 /// <summary>
 /// Transforms the RHS of the Join using the given Optimiser
 /// </summary>
 /// <param name="optimiser">Optimser</param>
 /// <returns></returns>
 public ISparqlAlgebra TransformRhs(IAlgebraOptimiser optimiser)
 {
     return new ExistsJoin(this._lhs, optimiser.Optimise(this._rhs), this._mustExist);
 }
 /// <summary>
 /// Transforms the RHS of the Join using the given Optimiser
 /// </summary>
 /// <param name="optimiser">Optimser</param>
 /// <returns></returns>
 public ISparqlAlgebra TransformRhs(IAlgebraOptimiser optimiser)
 {
     return new LeftJoin(this._lhs, optimiser.Optimise(this._rhs), this._filter);
 }
示例#37
0
 /// <summary>
 /// Transforms the LHS of the Join using the given Optimiser
 /// </summary>
 /// <param name="optimiser">Optimser</param>
 /// <returns></returns>
 public ISparqlAlgebra TransformLhs(IAlgebraOptimiser optimiser)
 {
     return new Join(optimiser.Optimise(this._lhs), this._rhs);
 }
示例#38
0
 /// <summary>
 /// Transforms both sides of the Join using the given Optimiser
 /// </summary>
 /// <param name="optimiser">Optimser</param>
 /// <returns></returns>
 public ISparqlAlgebra Transform(IAlgebraOptimiser optimiser)
 {
     return new AskUnion(optimiser.Optimise(this._lhs), optimiser.Optimise(this._rhs));
 }
示例#39
0
文件: Extend.cs 项目: jmahmud/RDFer
 /// <summary>
 /// Transforms the Inner Algebra using the given Optimiser
 /// </summary>
 /// <param name="optimiser">Optimiser</param>
 /// <returns></returns>
 public ISparqlAlgebra Transform(IAlgebraOptimiser optimiser)
 {
     if (optimiser is IExpressionTransformer)
     {
         return new Extend(optimiser.Optimise(this._inner), ((IExpressionTransformer)optimiser).Transform(this._expr), this._var);
     }
     else
     {
         return new Extend(optimiser.Optimise(this._inner), this._expr, this._var);
     }
 }
示例#40
0
 public ISparqlAlgebra Transform(IAlgebraOptimiser optimiser)
 {
     return new Extend(optimiser.Optimise(this._inner), this._expr, this._var);
 }
示例#41
0
 /// <summary>
 /// Transforms the Inner Algebra using the given Optimiser
 /// </summary>
 /// <param name="optimiser">Optimiser</param>
 /// <returns></returns>
 public ISparqlAlgebra Transform(IAlgebraOptimiser optimiser)
 {
     return(new Select(optimiser.Optimise(_pattern), IsSelectAll, _variables));
 }
示例#42
0
 /// <summary>
 /// Transforms the RHS of the Join using the given Optimiser
 /// </summary>
 /// <param name="optimiser">Optimser</param>
 /// <returns></returns>
 public ISparqlAlgebra TransformRhs(IAlgebraOptimiser optimiser)
 {
     return(new Minus(this._lhs, optimiser.Optimise(this._rhs)));
 }
 /// <summary>
 /// Transforms the RHS of the Join using the given Optimiser
 /// </summary>
 /// <param name="optimiser">Optimser</param>
 /// <returns></returns>
 public ISparqlAlgebra TransformRhs(IAlgebraOptimiser optimiser)
 {
     return(new ParallelUnion(this._lhs, optimiser.Optimise(this._rhs)));
 }
示例#44
0
 /// <summary>
 /// Transforms the Inner Algebra using the given Optimiser
 /// </summary>
 /// <param name="optimiser">Optimiser</param>
 /// <returns></returns>
 public ISparqlAlgebra Transform(IAlgebraOptimiser optimiser)
 {
     return(new Extend(optimiser.Optimise(this._inner), this._expr, this._var));
 }