Mage_Api_Model_Mysql4_Role Class Reference

Inheritance diagram for Mage_Api_Model_Mysql4_Role:

Mage_Core_Model_Mysql4_Abstract Mage_Core_Model_Resource_Abstract

List of all members.

Public Member Functions

 load (Mage_Core_Model_Abstract $object, $value, $field=null)

Protected Member Functions

 _construct ()
 _beforeSave (Mage_Core_Model_Abstract $object)


Detailed Description

Definition at line 27 of file Role.php.


Member Function Documentation

_beforeSave ( Mage_Core_Model_Abstract object  )  [protected]

Perform actions before object save

Parameters:
Varien_Object $object

Reimplemented from Mage_Core_Model_Mysql4_Abstract.

Definition at line 34 of file Role.php.

00035     {
00036         if ( !$object->getId() ) {
00037             $object->setCreated(now());
00038         }
00039         $object->setModified(now());
00040         return $this;
00041     }

_construct (  )  [protected]

Resource initialization

Reimplemented from Mage_Core_Model_Resource_Abstract.

Definition at line 29 of file Role.php.

00030     {
00031         $this->_init('api/role', 'role_id');
00032     }

load ( Mage_Core_Model_Abstract object,
value,
field = null 
)

Load an object

Parameters:
Mage_Core_Model_Abstract $object
mixed $value
string $field field to load by (defaults to model id)
Returns:
Mage_Core_Model_Mysql4_Abstract

Reimplemented from Mage_Core_Model_Mysql4_Abstract.

Definition at line 43 of file Role.php.

00044     {
00045         if (!intval($value) && is_string($value)) {
00046             $field = 'role_id';
00047         }
00048         return parent::load($object, $value, $field);
00049     }


The documentation for this class was generated from the following file:

Generated on Sat Jul 4 17:23:32 2009 for Magento by  doxygen 1.5.8