PHP Class Gc\Script\Model

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

Protected Properties

Property Type Description
$name string Table name

Public Methods

Method Description
delete ( ) : boolean Delete script model
fromArray ( array $array ) : Model Initiliaze from array
fromId ( integer $scriptId ) : Model Initiliaze from id
fromIdentifier ( integer $identifier ) : Model Initiliaze from id
getContent ( ) : string Return file contents
getFilePath ( ) : string Return file path
init ( integer $id = null ) : Model Initiliaze
save ( ) : integer Save script model

Method Details

delete() public method

Delete script model
public delete ( ) : boolean
return boolean

fromArray() public static method

Initiliaze from array
public static fromArray ( array $array ) : Model
$array array Data
return Model

fromId() public static method

Initiliaze from id
public static fromId ( integer $scriptId ) : Model
$scriptId integer Script id
return Model

fromIdentifier() public static method

Initiliaze from id
public static fromIdentifier ( integer $identifier ) : Model
$identifier integer Identifier
return Model

getContent() public method

Return file contents
public getContent ( ) : string
return string

getFilePath() public method

Return file path
public getFilePath ( ) : string
return string

init() public method

Initiliaze
public init ( integer $id = null ) : Model
$id integer Script id
return Model

save() public method

Save script model
public save ( ) : integer
return integer

Property Details

$name protected_oe property

Table name
protected string $name
return string