TraversalCursor
extends Cursor
in package
Represents an ArangoDB cursor for a Traversal query
Tags
Table of Contents
Methods
- __construct() : mixed
- Cursor constructor.
- __toString() : string
- Return an string representation of document.
- count() : int
- current() : Edge|Vertex|Path
- May return a path, a edge or a vertex. This is defined on statement.
- delete() : bool
- Deletes the cursor and frees the resources associated with it.
- fetch() : void
- Fetch more results from the server.
- getId() : mixed
- Returns the cursor ID
- isCached() : bool
- Return if the Cursor has cached results on server
- key() : mixed
- Return the key of the current element.
- next() : void
- Move forward to next element.
- rewind() : void
- Rewind the Iterator to the first element.
- valid() : bool
- Checks if current position is valid.
Methods
__construct()
Cursor constructor.
public
__construct(Connection $connection, StatementInterface $statement[, array<string|int, mixed> $options = [] ]) : mixed
Parameters
- $connection : Connection
-
Connection object to use.
- $statement : StatementInterface
-
Statement to perform on server.
- $options : array<string|int, mixed> = []
-
Options for cursor.
Tags
__toString()
Return an string representation of document.
public
__toString() : string
Return values
stringcount()
public
count() : int
Tags
Return values
intcurrent()
May return a path, a edge or a vertex. This is defined on statement.
public
current() : Edge|Vertex|Path
Non traversal queries will return all entries as vertex objects.
Tags
Return values
Edge|Vertex|Path —The object to be returned.
delete()
Deletes the cursor and frees the resources associated with it.
public
delete() : bool
Tags
Return values
boolfetch()
Fetch more results from the server.
public
fetch() : void
Tags
getId()
Returns the cursor ID
public
getId() : mixed
isCached()
Return if the Cursor has cached results on server
public
isCached() : bool
Return values
boolkey()
Return the key of the current element.
public
key() : mixed
next()
Move forward to next element.
public
next() : void
rewind()
Rewind the Iterator to the first element.
public
rewind() : void
valid()
Checks if current position is valid.
public
valid() : bool