PHP Class Efficiently\AuthorityController\ControllerResource

Afficher le fichier Open project: efficiently/authority-controller Class Usage Examples

Protected Properties

Свойство Type Description
$controller
$name
$options
$params

Méthodes publiques

Méthode Description
__construct ( $controller, $name = null, $options = [] )
addBeforeFilter ( $controller, $method, $args )
authorizeResource ( )
getCollectionScopeWithParams ( )
getNameByController ( $controller )
isParent ( )
loadAndAuthorizeResource ( )
loadResource ( )

Méthodes protégées

Méthode Description
buildResource ( )
extractKey ( $value )
fetchParent ( $name )
findResource ( )
getAuthorizationAction ( )
getCollectionActions ( )
getCollectionInstance ( )
getCollectionScope ( )
getCreateActions ( ) And the Rails 'create' action is named 'store' in Laravel.
getCurrentAbility ( ) Alias of getCurrentAuthority() to match CanCan API
getCurrentAuthority ( )
getIdKey ( )
getIdParam ( )
getInstanceName ( )
getName ( )
getNameFromController ( )
getNamespace ( $controllerName = null )
getNamespacedName ( )
getNewActions ( ) Alias of getCreateActions() to match CanCan API
getParentName ( )
getParentResource ( ) The object to load this resource through.
getResourceBase ( ) The object that methods (such as "find", "new" or "build") are called on.
getResourceClass ( ) only be used for authorization, not loading since there's no class to load through.
getResourceClassWithParent ( )
getResourceInstance ( )
getResourceParams ( )
getResourceParamsByNamespacedName ( )
getResourcePrimaryKey ( )
isMemberAction ( )
loadCollection ( )
loadResourceInstance ( )
loadedCollection ( )
loadedInstance ( )
setAttributes ( $resource )
setCollectionInstance ( $instance )
setResourceInstance ( $instance )

Method Details

__construct() public méthode

public __construct ( $controller, $name = null, $options = [] )

addBeforeFilter() public static méthode

public static addBeforeFilter ( $controller, $method, $args )

authorizeResource() public méthode

public authorizeResource ( )

buildResource() protected méthode

protected buildResource ( )

extractKey() protected méthode

protected extractKey ( $value )

fetchParent() protected méthode

protected fetchParent ( $name )

findResource() protected méthode

protected findResource ( )

getAuthorizationAction() protected méthode

protected getAuthorizationAction ( )

getCollectionActions() protected méthode

protected getCollectionActions ( )

getCollectionInstance() protected méthode

protected getCollectionInstance ( )

getCollectionScope() protected méthode

protected getCollectionScope ( )

getCollectionScopeWithParams() public méthode

getCreateActions() protected méthode

And the Rails 'create' action is named 'store' in Laravel.
protected getCreateActions ( )

getCurrentAbility() protected méthode

Alias of getCurrentAuthority() to match CanCan API
protected getCurrentAbility ( )

getCurrentAuthority() protected méthode

protected getCurrentAuthority ( )

getIdKey() protected méthode

protected getIdKey ( )

getIdParam() protected méthode

protected getIdParam ( )

getInstanceName() protected méthode

protected getInstanceName ( )

getName() protected méthode

protected getName ( )

getNameByController() public static méthode

public static getNameByController ( $controller )

getNameFromController() protected méthode

protected getNameFromController ( )

getNamespace() protected méthode

protected getNamespace ( $controllerName = null )

getNamespacedName() protected méthode

protected getNamespacedName ( )

getNewActions() protected méthode

Alias of getCreateActions() to match CanCan API
protected getNewActions ( )

getParentName() protected méthode

protected getParentName ( )

getParentResource() protected méthode

The object to load this resource through.
protected getParentResource ( )

getResourceBase() protected méthode

If the 'through' option is passed it will go through an association on that instance. If the 'shallow' option is passed it will use the getResourceClass() method if there's no parent If the 'singleton' option is passed it won't use the association because it needs to be handled later.
protected getResourceBase ( )

getResourceClass() protected méthode

only be used for authorization, not loading since there's no class to load through.
protected getResourceClass ( )

getResourceClassWithParent() protected méthode

getResourceInstance() protected méthode

protected getResourceInstance ( )

getResourceParams() protected méthode

protected getResourceParams ( )

getResourceParamsByNamespacedName() protected méthode

getResourcePrimaryKey() protected méthode

protected getResourcePrimaryKey ( )

isMemberAction() protected méthode

protected isMemberAction ( )

isParent() public méthode

public isParent ( )

loadAndAuthorizeResource() public méthode

loadCollection() protected méthode

protected loadCollection ( )

loadResource() public méthode

public loadResource ( )

loadResourceInstance() protected méthode

protected loadResourceInstance ( )

loadedCollection() protected méthode

protected loadedCollection ( )

loadedInstance() protected méthode

protected loadedInstance ( )

setAttributes() protected méthode

protected setAttributes ( $resource )

setCollectionInstance() protected méthode

protected setCollectionInstance ( $instance )

setResourceInstance() protected méthode

protected setResourceInstance ( $instance )

Property Details

$controller protected_oe property

protected $controller

$name protected_oe property

protected $name

$options protected_oe property

protected $options

$params protected_oe property

protected $params