CursorField uses ConstantsTrait
Field names exchanged with the ArangoDB server through the AQL cursor API (`/_api/cursor`).
Covers both directions:
- request body fields sent on
POST /_api/cursor(query,bindVars, plus the cursor options forwarded as-is by the caller —count,batchSize,fullCount, …), - response body fields returned by the server in the initial response
and in each subsequent batch fetch (
result,hasMore,id,count,extra).
Tags
Table of Contents
Constants
- BATCH_SIZE : string = 'batchSize'
- Cursor option — preferred batch size for result paging. Lives at the root of the `POST /_api/cursor` request body.
- BIND_VARS : string = 'bindVars'
- Map of bind name → value sent on `POST /_api/cursor`.
- CACHE : string = 'cache'
- Cursor option — enable the per-query plan cache. Lives at the root of the `POST /_api/cursor` request body.
- COUNT : string = 'count'
- Server-side total count of result rows. Returned in the response only when the request set `count: true`.
- EXTRA : string = 'extra'
- Extra response metadata (warnings, stats, profile, …).
- FULL_COUNT : string = 'fullCount'
- Total number of result rows that would have been returned had the query been executed without a LIMIT clause.
- HAS_MORE : string = 'hasMore'
- Flag carried in the response body indicating that more batches remain to be fetched.
- ID : string = 'id'
- Server-side cursor identifier, present in the response only when more batches remain (i.e. when `hasMore` is true).
- MAX_RUNTIME : string = 'maxRuntime'
- Cursor option — maximum amount of wall-clock time the server may spend on the query before terminating it (seconds, fractional).
- MEMORY_LIMIT : string = 'memoryLimit'
- Cursor option — maximum amount of RAM (in bytes) the query may allocate before being aborted. Lives at the root of the `POST /_api/cursor` request body.
- OPTIMIZER : string = 'optimizer'
- Nested cursor option — optimizer control (e.g. `[ 'rules' => [ '-use-indexes' ] ]`).
- OPTIONS : string = 'options'
- Nested object on `POST /_api/cursor` carrying the non-root cursor options recognised by the server (`fullCount`, `profile`, `stream`, `maxRuntime`, `failOnWarning`, `optimizer`, …).
- PROFILE : string = 'profile'
- Nested cursor option — enable query profiling. `1` collects per-phase timings + statistics; `2` adds detailed per-node execution stats. Lives under {@see self::OPTIONS}. The results surface in the cursor's `extra` (`stats` / `profile`).
- QUERY : string = 'query'
- Raw AQL query string sent on `POST /_api/cursor`.
- RESULT : string = 'result'
- Per-batch array of rows returned by the server.
- ROOT_OPTIONS : array<string|int, mixed> = [self::COUNT, self::BATCH_SIZE, self::CACHE, se...
- Cursor options that ArangoDB accepts at the **root** of the `POST /_api/cursor` request body. Anything else (`fullCount`, `profile`, `stream`, `maxRuntime`, `failOnWarning`, `optimizer`, …) must be nested under {@see OPTIONS} so the server actually applies it.
- STATS : string = 'stats'
- Sub-key of `extra` containing query execution statistics (`fullCount`, `writesExecuted`, `executionTime`, `scannedFull`, …).
- TTL : string = 'ttl'
- Cursor option — server-side time-to-live of the cursor (in seconds). The cursor is dropped automatically when no batch is pulled within that window. Lives at the root of the `POST /_api/cursor` request body.
Constants
BATCH_SIZE
Cursor option — preferred batch size for result paging. Lives at the root of the `POST /_api/cursor` request body.
public
string
BATCH_SIZE
= 'batchSize'
BIND_VARS
Map of bind name → value sent on `POST /_api/cursor`.
public
string
BIND_VARS
= 'bindVars'
Note: the server expects a JSON object (never an array). When the
map is empty, callers should still pass an empty object (cast
(object) []) so JSON encoding does not produce [].
CACHE
Cursor option — enable the per-query plan cache. Lives at the root of the `POST /_api/cursor` request body.
public
string
CACHE
= 'cache'
COUNT
Server-side total count of result rows. Returned in the response only when the request set `count: true`.
public
string
COUNT
= 'count'
EXTRA
Extra response metadata (warnings, stats, profile, …).
public
string
EXTRA
= 'extra'
FULL_COUNT
Total number of result rows that would have been returned had the query been executed without a LIMIT clause.
public
string
FULL_COUNT
= 'fullCount'
Carried in two places:
- request option (
options.fullCount: true) — must be set for the server to compute this value, - response payload, nested under
extra.stats.fullCount.
HAS_MORE
Flag carried in the response body indicating that more batches remain to be fetched.
public
string
HAS_MORE
= 'hasMore'
ID
Server-side cursor identifier, present in the response only when more batches remain (i.e. when `hasMore` is true).
public
string
ID
= 'id'
MAX_RUNTIME
Cursor option — maximum amount of wall-clock time the server may spend on the query before terminating it (seconds, fractional).
public
string
MAX_RUNTIME
= 'maxRuntime'
Carried under the nested options.{...} sub-object on
POST /_api/cursor.
MEMORY_LIMIT
Cursor option — maximum amount of RAM (in bytes) the query may allocate before being aborted. Lives at the root of the `POST /_api/cursor` request body.
public
string
MEMORY_LIMIT
= 'memoryLimit'
OPTIMIZER
Nested cursor option — optimizer control (e.g. `[ 'rules' => [ '-use-indexes' ] ]`).
public
string
OPTIMIZER
= 'optimizer'
Lives under self::OPTIONS.
OPTIONS
Nested object on `POST /_api/cursor` carrying the non-root cursor options recognised by the server (`fullCount`, `profile`, `stream`, `maxRuntime`, `failOnWarning`, `optimizer`, …).
public
string
OPTIONS
= 'options'
Distinct from the top-level options (count, batchSize, ttl,
cache, memoryLimit) which live at the body root.
PROFILE
Nested cursor option — enable query profiling. `1` collects per-phase timings + statistics; `2` adds detailed per-node execution stats. Lives under {@see self::OPTIONS}. The results surface in the cursor's `extra` (`stats` / `profile`).
public
string
PROFILE
= 'profile'
QUERY
Raw AQL query string sent on `POST /_api/cursor`.
public
string
QUERY
= 'query'
RESULT
Per-batch array of rows returned by the server.
public
string
RESULT
= 'result'
ROOT_OPTIONS
Cursor options that ArangoDB accepts at the **root** of the `POST /_api/cursor` request body. Anything else (`fullCount`, `profile`, `stream`, `maxRuntime`, `failOnWarning`, `optimizer`, …) must be nested under {@see OPTIONS} so the server actually applies it.
public
array<string|int, mixed>
ROOT_OPTIONS
= [self::COUNT, self::BATCH_SIZE, self::CACHE, self::MEMORY_LIMIT, self::TTL]
QUERY and BIND_VARS are intentionally absent — they are
required body fields, not options, and are extracted before any
root-vs-nested dispatch happens.
STATS
Sub-key of `extra` containing query execution statistics (`fullCount`, `writesExecuted`, `executionTime`, `scannedFull`, …).
public
string
STATS
= 'stats'
TTL
Cursor option — server-side time-to-live of the cursor (in seconds). The cursor is dropped automatically when no batch is pulled within that window. Lives at the root of the `POST /_api/cursor` request body.
public
string
TTL
= 'ttl'