Symfony2 API
Class

Symfony\Component\BrowserKit\History

class History

History.

Methods

__construct()

Constructor.

clear()

Clears the history.

add(Request $request)

Adds a Request to the history.

Boolean isEmpty()

Returns true if the history is empty.

Request back()

Goes back in the history.

Request forward()

Goes forward in the history.

Request current()

Returns the current element in the history.

Details

at line 27
public __construct()

Constructor.

at line 35
public clear()

Clears the history.

at line 46
public add(Request $request)

Adds a Request to the history.

Parameters

Request $request A Request instance

at line 58
public Boolean isEmpty()

Returns true if the history is empty.

Return Value

Boolean true if the history is empty, false otherwise

at line 70
public Request back()

Goes back in the history.

Return Value

Request A Request instance

Exceptions

LogicException if the stack is already on the first page

at line 86
public Request forward()

Goes forward in the history.

Return Value

Request A Request instance

Exceptions

LogicException if the stack is already on the last page

at line 102
public Request current()

Returns the current element in the history.

Return Value

Request A Request instance

Exceptions

LogicException if the stack is empty