Exemplo n.º 1
0
 private Path GetFirstPath(Traverser traverse)
 {
     using (ResourceIterator <Path> iterator = traverse.GetEnumerator())
     {
         return(Iterators.first(iterator));
     }
 }
Exemplo n.º 2
0
//JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes:
//ORIGINAL LINE: @Test public void testPathIterator()
        public virtual void TestPathIterator()
        {
            Traverser traverse = GraphDb.traversalDescription().evaluator(atDepth(4)).traverse(Node("A"));

            using (ResourceIterator <Path> resourceIterator = traverse.GetEnumerator())
            {
//JAVA TO C# CONVERTER TODO TASK: Java iterators are only converted within the context of 'while' and 'for' loops:
                Path path = resourceIterator.next();
                AssertPathIsCorrect(path);
            }
        }