That would be EXCLUDE_AND_PRUNE.

On Thu, Apr 7, 2011 at 7:58 AM, Dario Rexin <dario.re...@xing.com> wrote:

> Hi Peter, yes that would be not to include the path in the result set.
>
>
>
> On 07.04.2011, at 07:01, "Peter Neubauer" <
> peter.neuba...@neotechnology.com> wrote:
>
> > Dario,
> > I am not quite sure I understand what you mean by "drop" is that not
> > to include the path into the result or prune or something else? Do you
> > have a concrete example of this, maybe a simple toy graph test with
> > toy information?
> >
> > Cheers,
> >
> > /peter neubauer
> >
> > GTalk:      neubauer.peter
> > Skype       peter.neubauer
> > Phone       +46 704 106975
> > LinkedIn   http://www.linkedin.com/in/neubauer
> > Twitter      http://twitter.com/peterneubauer
> >
> > http://www.neo4j.org               - Your high performance graph
> database.
> > http://startupbootcamp.org/    - Ă–resund - Innovation happens HERE.
> > http://www.thoughtmade.com - Scandinavia's coolest Bring-a-Thing party.
> >
> >
> >
> > On Wed, Apr 6, 2011 at 6:35 PM, Dario Rexin <dario.re...@xing.com>
> wrote:
> >> Hello,
> >>
> >> we are trying to construct an Evaluator that will select only one node
> from the middle of a path and include it in the result. We do have a
> specific path we are looking for and the endNode is stored in 'end'. Now
> what we would like to do is have an Evaluator like this:
> >>
> >>          import org.neo4j.graphdb.traversal.
> >> Evaluator;
> >>
> >>          new Evaluator(){
> >>            @Override
> >>            public Evaluation evaluate(org.neo4j.graphdb.Path path) {
> >>                if(path.length() > 3) {
> >>                    return Evaluation.EXCLUDE_AND_PRUNE;
> >>                } else if (path.length() == 2) {
> >>                    return Evaluation.INCLUDE_AND_CONTINUE;
> >>                } else if (path.length() < 2){
> >>                    return Evaluation.EXCLUDE_AND_CONTINUE;
> >>                } else {
> >>                    return path.endNode().getId() == end.getId() ?
> Evaluation.EXCLUDE_AND_PRUNE : Evaluation.DROP_PATH_AND_PRUNE;
> >>                }
> >>            }
> >>          }
> >>
> >> The decision on whether to accept or drop a path is based on wether we
> have reached the endNode. That's why we would like to use something like
> DROP_PATH_AND_PRUNE, which doesn't exist. What are we missing?
> >>
> >> Any help appreciated!
> >>
> >> Thanks,
> >> Stephan and Dario
> >> _______________________________________________
> >> Neo4j mailing list
> >> User@lists.neo4j.org
> >> https://lists.neo4j.org/mailman/listinfo/user
> >>
> > _______________________________________________
> > Neo4j mailing list
> > User@lists.neo4j.org
> > https://lists.neo4j.org/mailman/listinfo/user
> _______________________________________________
> Neo4j mailing list
> User@lists.neo4j.org
> https://lists.neo4j.org/mailman/listinfo/user
>



-- 
Tobias Ivarsson <tobias.ivars...@neotechnology.com>
Hacker, Neo Technology
www.neotechnology.com
Cellphone: +46 706 534857
_______________________________________________
Neo4j mailing list
User@lists.neo4j.org
https://lists.neo4j.org/mailman/listinfo/user

Reply via email to