Properties

$content

$content : string|array<mixed,string>

Type

string|array<mixed,string> — Content of the ussd menu or the starting

$next

$next : string|array<mixed,string>

Type

string|array<mixed,string> — Link to the next menu tag

$page

$page : integer

Type

integer — Current page number of menu

$number_per_page

$number_per_page : integer

Type

integer — Total number of pages of the menu

$iterable_list

$iterable_list : array<mixed,object>|array<mixed,string>

Type

array<mixed,object>|array<mixed,string> — List of object to put on page

$iterator

$iterator : array<mixed,string>|array<mixed,object>|null

Type

array<mixed,string>|array<mixed,object>|null — index and parameter of the iterable_list to display

$end

$end : array<mixed,string>|null

Type

array<mixed,string>|null — Content to append to menu's ending

$processNext

$processNext : null|string

Type

null|string — Key to show if there is next page

$processBack

$processBack : null|string

Type

null|string — Key to show if there is back page

$processPrevious

$processPrevious : null|string

Type

null|string — Key to show if there is a previous page

$processBeginning

$processBeginning : null|string

Type

null|string — Key to show if there is beginning page

Methods

__construct()

__construct(string|array<mixed,string>  $content, string|array<mixed,string>  $next, integer  $page = 1, integer  $number_per_page = null, array<mixed,object>|array<mixed,string>|null  $iterable_list = null, array<mixed,string>|null  $iterator = null, string|array<mixed,string>|null  $end = null) 

View constructor.

It used to create a new instance of the View Class.

Parameters

string|array<mixed,string> $content
string|array<mixed,string> $next
integer $page
integer $number_per_page
array<mixed,object>|array<mixed,string>|null $iterable_list
array<mixed,string>|null $iterator
string|array<mixed,string>|null $end

setContent()

setContent(string|array<mixed,string>  $content) 

View public function setContent.

Parameters

string|array<mixed,string> $content

setNext()

setNext(string|array<mixed,string>  $next) 

View public function setNext.

Parameters

string|array<mixed,string> $next

setPage()

setPage(integer  $page) 

View public function setPage.

Parameters

integer $page

setNumberPerPage()

setNumberPerPage(integer  $number_per_page) 

View public function setNumberPerPage.

Parameters

integer $number_per_page

setIterableList()

setIterableList(array<mixed,object>|array<mixed,string>  $iterable_list) 

View public function setIterableList.

Parameters

array<mixed,object>|array<mixed,string> $iterable_list

setIterator()

setIterator(array<mixed,string>|null  $iterator) 

View public function setIterator.

Parameters

array<mixed,string>|null $iterator

setEnd()

setEnd(string|array<mixed,string>  $end) 

View public function setEnd.

Parameters

string|array<mixed,string> $end

getContent()

getContent() : string

View public function getContent.

Returns

string

getNext()

getNext() : string

View public function getNext.

Returns

string

getPage()

getPage() : integer

View public function getPage.

Returns

integer

getNumberPerPage()

getNumberPerPage() : integer

View public function getNumberPerPage.

Returns

integer

getIterableList()

getIterableList() : array<mixed,object>|array<mixed,string>

View public function getIterableList.

Returns

array<mixed,object>|array<mixed,string>

getIterator()

getIterator() : array<mixed,string>

View public function getIterator.

Returns

array<mixed,string>

getEnd()

getEnd() : string

View public function getEnd.

Returns

string

parseToString()

parseToString() : string

View public function parseToString.

It compiles the menus to String format possible to display on phone

Returns

string

arrayToList()

arrayToList(integer  $page, integer  $number_per_page, array<mixed,string>|array<mixed,array>  $array, null|array<mixed,string>  $nested_indices = null) : string

View public static function arrayToList It converts a given array to list in string format possible to display on phone

Parameters

integer $page
integer $number_per_page
array<mixed,string>|array<mixed,array> $array
null|array<mixed,string> $nested_indices

Returns

string

setProcessNext()

setProcessNext(string  $key) 

View public static function setProcessNext.

Parameters

string $key

setProcessBack()

setProcessBack(string  $key) 

View public static function setProcessBack.

Parameters

string $key

setProcessPrevious()

setProcessPrevious(string  $key) 

View public static function setProcessPrevious.

Parameters

string $key

setProcessBeginning()

setProcessBeginning(string  $key) 

View public static function setProcessBeginning.

Parameters

string $key

getProcessNext()

getProcessNext() : null|string

View public static function getProcessNext.

Returns

null|string

getProcessBack()

getProcessBack() : null|string

View public static function getProcessBack.

Returns

null|string

getProcessPrevious()

getProcessPrevious() : null|string

View public static function getProcessPrevious.

Returns

null|string

getProcessBeginning()

getProcessBeginning() : null|string

View public static function getProcessBeginning,

Returns

null|string

makeList()

makeList() : string

View public function makeList It generates the list for a particular page

Returns

string