Method | Description | |
---|---|---|
dispense ( string $type, integer $number = 1, boolean $alwaysReturnArray = FALSE ) : RedBeanPHP\OODBBean | Dispenses a new bean (a OODBBean Bean Object) of the specified type. Always use this function to get an empty bean object. Never instantiate a OODBBean yourself because it needs to be configured before you can use it with RedBean. This function applies the appropriate initialization / configuration for you. | |
load ( string $type, integer $id ) : RedBeanPHP\OODBBean | Loads a bean from the object database. |
Method | Description | |
---|---|---|
handleException ( Exception $exception ) : void | Handles exceptions. | |
processAdditions ( RedBeanPHP\OODBBean $bean, array $ownAdditions ) : void | Part of the store() functionality. | |
storeBean ( RedBeanPHP\OODBBean $bean ) : void | Stores a cleaned bean; i.e. only scalar values. This is the core of the store() method. When all lists and embedded beans (parent objects) have been processed and removed from the original bean the bean is passed to this method to be stored in the database. |
public dispense ( string $type, integer $number = 1, boolean $alwaysReturnArray = FALSE ) : RedBeanPHP\OODBBean | ||
$type | string | type of bean you want to dispense |
$number | integer | number of beans you would like to get |
$alwaysReturnArray | boolean | if TRUE always returns the result as an array |
return | RedBeanPHP\OODBBean |
protected handleException ( Exception $exception ) : void | ||
$exception | Exception | exception to handle |
return | void |
protected processAdditions ( RedBeanPHP\OODBBean $bean, array $ownAdditions ) : void | ||
$bean | RedBeanPHP\OODBBean | bean to process |
$ownAdditions | array | list of addition beans in own-list |
return | void |