PHP Class Gc\View\Collection

Inheritance: extends Gc\Db\AbstractTable
Show file Open project: gotcms/gotcms Class Usage Examples

Protected Properties

Property Type Description
$elements array List of \Gc\View\Model
$name string Table name

Public Methods

Method Description
addElement ( Model $view ) : Collection Add view
clearElements ( ) : Collection Clear elements
delete ( ) : boolean delete properties
getElements ( ) : array Get all elements store in $elements
getSelect ( ) : array Get array for input select
getViews ( boolean $forceReload = false ) : array Get views
init ( integer $documentTypeId = null ) : void Initiliaze collection
save ( ) : boolean Save properties

Method Details

addElement() public method

Add view
public addElement ( Model $view ) : Collection
$view Model View model
return Collection

clearElements() public method

Clear elements
public clearElements ( ) : Collection
return Collection

delete() public method

delete properties
public delete ( ) : boolean
return boolean

getElements() public method

Get all elements store in $elements
public getElements ( ) : array
return array

getSelect() public method

Get array for input select
public getSelect ( ) : array
return array

getViews() public method

Get views
public getViews ( boolean $forceReload = false ) : array
$forceReload boolean To initiliaze views
return array

init() public method

Initiliaze collection
public init ( integer $documentTypeId = null ) : void
$documentTypeId integer Optional document type id
return void

save() public method

Save properties
public save ( ) : boolean
return boolean

Property Details

$elements protected property

List of \Gc\View\Model
protected array $elements
return array

$name protected property

Table name
protected string $name
return string