Menu

## TraversalCursor extends Cursor
in package

TraversalCursor.php : 18

Represents an ArangoDB cursor for a Traversal query

##### Tags

author

  Lucas S. Vieira

### 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.php : 56

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

throws
  CursorException|GuzzleException

#### __toString()

Cursor.php : 71

Return an string representation of document.

`public __toString() : string`

##### Return values

string

#### count()

Cursor.php : 227
`public count() : int`

##### Tags

inheritDoc

##### Return values

int

#### current()

TraversalCursor.php : 28

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

throws
  InvalidParameterException|MissingParameterException

##### Return values

Edge|Vertex|Path —

The object to be returned.

#### delete()

Cursor.php : 151

Deletes the cursor and frees the resources associated with it.

`public delete() : bool`

##### Tags

throws
  CursorException

##### Return values

bool

#### fetch()

Cursor.php : 201

Fetch more results from the server.

`public fetch() : void`

##### Tags

throws
  CursorException

#### getId()

Base.php : 184

Returns the cursor ID

`public getId() : mixed`

#### isCached()

Base.php : 174

Return if the Cursor has cached results on server

`public isCached() : bool`

##### Return values

bool

#### key()

Cursor.php : 108

Return the key of the current element.

`public key() : mixed`

#### next()

Cursor.php : 98

Move forward to next element.

`public next() : void`

#### rewind()

Cursor.php : 139

Rewind the Iterator to the first element.

`public rewind() : void`

#### valid()

Cursor.php : 120

Checks if current position is valid.

`public valid() : bool`

##### Tags

throws
  CursorException

##### Return values

bool

## Search results