internal TraversalQuery(IDomainModel domain)
        {
            DomainModel   = domain;
            PathTraverser = new GraphBreadthFirstTraverser();
            Evaluator     = new AllEvaluator();
            UnicityPolicy = new GlobalNodeUnicity();

            var provider = domain as Hyperstore.Modeling.Domain.IHyperGraphProvider;

            System.Diagnostics.Debug.Assert(provider != null);
            IncidencesIterator = new DefaultIncidencesIterator(Direction.Outgoing, provider.InnerGraph as HyperGraph.HyperGraph);
        }
Beispiel #2
0
 ///-------------------------------------------------------------------------------------------------
 /// <summary>
 ///  Unicity policy.
 /// </summary>
 /// <param name="policy">
 ///  The policy.
 /// </param>
 /// <returns>
 ///  A TraversalBuilder.
 /// </returns>
 ///-------------------------------------------------------------------------------------------------
 public TraversalBuilder UnicityPolicy(IGraphTraversalUnicityPolicy policy)
 {
     Contract.Requires(policy, "policy");
     _query.UnicityPolicy = policy;
     return(this);
 }