trait ManagesLoops

Constants

protected LOOPS_STACK_CONTEXT_KEY

The context key for loops stack.

Methods

void
addLoop(mixed $data)

Add new loop to the stack.

void
incrementLoopIndices()

Increment the top loop's indices.

void
popLoop()

Pop a loop from the top of the loop stack.

stdClass|null
getLastLoop()

Get an instance of the last loop in the stack.

array
getLoopStack()

Get the entire loop stack.

void
flushLoops()

Flush the loop stack.

Details

at line 21
void addLoop(mixed $data)

Add new loop to the stack.

Parameters

mixed $data

Return Value

void

at line 49
void incrementLoopIndices()

Increment the top loop's indices.

Return Value

void

at line 70
void popLoop()

Pop a loop from the top of the loop stack.

Return Value

void

at line 80
stdClass|null getLastLoop()

Get an instance of the last loop in the stack.

Return Value

stdClass|null

at line 92
array getLoopStack()

Get the entire loop stack.

Return Value

array

at line 100
protected void flushLoops()

Flush the loop stack.

Return Value

void