Re: [Neo4j] zero fromDepth and toDepth

2011-11-15 Thread Peter Neubauer
Done, enjoy! https://github.com/neo4j/community/issues/80 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 - NO

Re: [Neo4j] zero fromDepth and toDepth

2011-11-03 Thread Peter Neubauer
We can do this after 1.5. 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              - NOSQL for the Enterprise. http://st

Re: [Neo4j] zero fromDepth and toDepth

2011-11-03 Thread Mattias Persson
Sure, but implementations using it will break then. Maybe not this close to release? hard decision. 2011/11/3 Peter Neubauer > So, > do we fix the implementation to match (see > https://github.com/neo4j/community/issues/80) or adjust the JavaDoc? I > kinda think it makes sense to change the code

Re: [Neo4j] zero fromDepth and toDepth

2011-11-03 Thread Peter Neubauer
So, do we fix the implementation to match (see https://github.com/neo4j/community/issues/80) or adjust the JavaDoc? I kinda think it makes sense to change the code, have written tests for it. Cheers, /peter neubauer GTalk:      neubauer.peter Skype       peter.neubauer Phone       +46 704 106975

Re: [Neo4j] zero fromDepth and toDepth

2011-11-03 Thread Mattias Persson
Right, the toDepth implementation isn't matching the javadoc and it is a bit confusing. 2011/11/3 Alex > Done: > > > http://neo4jdb.lighthouseapp.com/projects/77609-neo4j-community/tickets/17-consisnte-behavior-of-fromdepth-todepth-and-atdepth > > there's a typo in the title... time to get some

Re: [Neo4j] zero fromDepth and toDepth

2011-11-02 Thread Alex
Done: http://neo4jdb.lighthouseapp.com/projects/77609-neo4j-community/tickets/17-consisnte-behavior-of-fromdepth-todepth-and-atdepth there's a typo in the title... time to get some sleep :) Alex -- View this message in context: http://neo4j-community-discussions.438527.n3.nabble.com/zero-fromD

Re: [Neo4j] zero fromDepth and toDepth

2011-11-02 Thread Peter Neubauer
Mmmh, let me do a testcase on this ... can you raise an issue? 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              

Re: [Neo4j] zero fromDepth and toDepth

2011-11-02 Thread Alex
That sounds a bit bizarre: in my code, fromDepth(n) && toDepth(n) seems to be working like atDepth(n) if n>0 (that's what should be happening, isn't it?) Alex -- View this message in context: http://neo4j-community-discussions.438527.n3.nabble.com/zero-fromDepth-and-toDepth-tp3474825p3476058.htm

Re: [Neo4j] zero fromDepth and toDepth

2011-11-02 Thread Peter Neubauer
Well, fromDepth is public static Evaluator fromDepth( final int depth ) { return new Evaluator() { public Evaluation evaluate( Path path ) { return path.length() < depth ? Evaluation.EXCLUDE_AND_CONTINUE : Evaluation.INCLUDE_AND_CONTINUE;

Re: [Neo4j] zero fromDepth and toDepth

2011-11-02 Thread Alex
Hi Peter it admittedly makes little sense to use fromDepth(0) & toDepth(0) because there's obviously no need to run the query at all. Anyway, I'd expect a behavior consistent with, for example fromDepth(1) & toDepth(1), which returns only nodes at depth 1 (if I'm not mistaken). So, I'd definitely

Re: [Neo4j] zero fromDepth and toDepth

2011-11-02 Thread Michael Hunger
What about atDepth(0) ? Michael Am 03.11.2011 um 03:33 schrieb Peter Neubauer: > Alex, > looking at the source, the Evaluators.toDepth() does: > > public static Evaluator toDepth( final int depth ) >{ >return new Evaluator() >{ >public Evaluation evaluate( Path p

Re: [Neo4j] zero fromDepth and toDepth

2011-11-02 Thread Peter Neubauer
Alex, looking at the source, the Evaluators.toDepth() does: public static Evaluator toDepth( final int depth ) { return new Evaluator() { public Evaluation evaluate( Path path ) { return path.length() < depth ? Evaluation.INCLUDE_AND_CONT

[Neo4j] zero fromDepth and toDepth

2011-11-02 Thread Alex
Hi everybody when setting fromDepth and toDepth both at zero, like in the following code Traversal.description.breadthFirst .evaluator(Evaluators.fromDepth(0)) .evaluator(Evaluators.toDepth(0)) I'm expecting to get only the start node, but I don't. Am I missing anything? Thanks! Cheers Ale