PHP Class Xpressengine\Permission\Repositories\DatabaseRepository

Author: XE Developers ([email protected])
Inheritance: implements Xpressengine\Permission\PermissionRepository
Exibir arquivo Open project: xpressengine/xpressengine Class Usage Examples

Protected Properties

Property Type Description
$conn Xpressengine\Database\VirtualConnectionInterface Connection instance
$table string Table name

Public Methods

Method Description
__construct ( Xpressengine\Database\VirtualConnectionInterface $conn ) Constructor
affiliate ( Permission $item, string $to ) : void affiliated to another registered
delete ( Permission $item ) : integer Delete register information
fetchAncestor ( string $siteKey, string $name ) : array Returns ancestor of item
fetchDescendant ( string $siteKey, string $name ) : array Returns descendant of item
findByName ( string $siteKey, string $name ) : Permission Find a registered by type and name
foster ( Permission $item, string $to ) : void Parent Changing with descendant
getNow ( ) : string Now datetime string
insert ( Permission $item ) : Permission Insert register information
update ( Permission $item ) : Permission Update register information

Protected Methods

Method Description
createItem ( array $attributes ) : Permission Create a new registered object instance

Method Details

__construct() public method

Constructor
public __construct ( Xpressengine\Database\VirtualConnectionInterface $conn )
$conn Xpressengine\Database\VirtualConnectionInterface Connection instance

affiliate() public method

affiliated to another registered
public affiliate ( Permission $item, string $to ) : void
$item Xpressengine\Permission\Permission permission instance
$to string parent name
return void

createItem() protected method

Create a new registered object instance
protected createItem ( array $attributes ) : Permission
$attributes array attributes array
return Xpressengine\Permission\Permission

delete() public method

Delete register information
public delete ( Permission $item ) : integer
$item Xpressengine\Permission\Permission permission instance
return integer affecting statement

fetchAncestor() public method

Returns ancestor of item
public fetchAncestor ( string $siteKey, string $name ) : array
$siteKey string site key
$name string target name
return array

fetchDescendant() public method

Returns descendant of item
public fetchDescendant ( string $siteKey, string $name ) : array
$siteKey string site key
$name string target name
return array

findByName() public method

Find a registered by type and name
public findByName ( string $siteKey, string $name ) : Permission
$siteKey string site key
$name string target name
return Xpressengine\Permission\Permission

foster() public method

Parent Changing with descendant
public foster ( Permission $item, string $to ) : void
$item Xpressengine\Permission\Permission permission instance
$to string parent name
return void

getNow() public method

Now datetime string
public getNow ( ) : string
return string

insert() public method

Insert register information
public insert ( Permission $item ) : Permission
$item Xpressengine\Permission\Permission permission instance
return Xpressengine\Permission\Permission

update() public method

Update register information
public update ( Permission $item ) : Permission
$item Xpressengine\Permission\Permission permission instance
return Xpressengine\Permission\Permission

Property Details

$conn protected_oe property

Connection instance
protected VirtualConnectionInterface,Xpressengine\Database $conn
return Xpressengine\Database\VirtualConnectionInterface

$table protected_oe property

Table name
protected string $table
return string