AdminAccessRoleReader

Implements \AdminAccessRoleReaderInterface

Class AdminAccessRoleReader

category

System

package

AdminAccess

subpackage

Readers

Methods

AdminAccessRoleReader constructor.

__construct(\CI_DB_query_builder $queryBuilder, \AdminAccessRoleFactoryInterface $roleFactory, \LanguageProviderInterface $languageProvider) 

Arguments

$queryBuilder

\CI_DB_query_builder

Query builder.

$roleFactory

\AdminAccessRoleFactoryInterface

Role Factory.

$languageProvider

\LanguageProviderInterface

Language provider.

Creates a role object by a given array with the role data.

_createAdminAccessRoleByArray(array $roleData) : \AdminAccessRoleInterface

Arguments

$roleData

array

Role data.

Response

\AdminAccessRoleInterface

Role object.

Returns all roles of a certain user by a given customer ID.

getAll() : \AdminAccessRoleCollection

Response

\AdminAccessRoleCollection

Role collection with all available roles.

Returns a role object by a given role ID.

getByCustomerId(\IdType $customerId) : \AdminAccessRoleCollection
Throws
\RoleNotFoundException

Arguments

$customerId

\IdType

Customer ID.

Response

\AdminAccessRoleCollection

Role collection with all roles of a certain user.

Returns all available roles as a role collection.

getById(\IdType $roleId) : \AdminAccessRoleInterface
Throws
\RoleNotFoundException

When role is not found in db.

Arguments

$roleId

\IdType

Role ID.

Response

\AdminAccessRoleInterface

Role object.

Properties

queryBuilder

queryBuilder : \CI_DB_query_builder
var

Type(s)

\CI_DB_query_builder

roleFactory

roleFactory : \AdminAccessRoleFactoryInterface

rolesTable

rolesTable : string
var

Type(s)

string

rolesMetaTable

rolesMetaTable : string
var

Type(s)

string

customersTable

customersTable : string
var

Type(s)

string

languageProvider

languageProvider : \LanguageProviderInterface