function access_grant_load in Access Control Kit 7
Loads an access grant by ID.
Parameters
int $gid: The grant ID.
bool $reset: (optional) Whether to reset the internal cache. Defaults to FALSE.
Return value
object|false An access grant, or FALSE if the grant is not found.
5 calls to access_grant_load()
- AccessAPITest::testHandlerMethods in ./
access.test - Test access arbitration through our dummy handler.
- AccessGrantFunctionTest::testGrantCRUD in ./
access.test - Test basic create, read, update, and delete functions.
- AccessGrantFunctionTest::testGrantStaticReset in ./
access.test - Ensure that the access grant static reset works correctly.
- AccessGrantInterfaceTest::testGrantDelete in ./
access.test - Delete an access grant via the user interface.
- AccessSchemeInterfaceTest::testSchemeDelete in ./
access.test - Delete an access scheme via the user interface.
File
- ./
access.module, line 102 - The access control kit module.
Code
function access_grant_load($gid, $reset = FALSE) {
$grants = access_grant_load_multiple(array(
$gid,
), $reset);
return reset($grants);
}