Public Member Functions | |
getFlagData () | |
setFlagData ($value) | |
loadSelf () | |
Protected Member Functions | |
_construct () | |
_beforeSave () | |
Protected Attributes | |
$_flagCode = null |
Definition at line 35 of file Flag.php.
_beforeSave | ( | ) | [protected] |
Processing object before save data
Reimplemented from Mage_Core_Model_Abstract.
Reimplemented in Mage_CatalogIndex_Model_Catalog_Index_Flag.
Definition at line 58 of file Flag.php.
00059 { 00060 if (is_null($this->_flagCode)) { 00061 Mage::throwException(Mage::helper('core')->__('Please define flag code.')); 00062 } 00063 00064 $this->setFlagCode($this->_flagCode); 00065 $this->setLastUpdate(date('Y-m-d H:i:s')); 00066 00067 return parent::_beforeSave(); 00068 }
_construct | ( | ) | [protected] |
Init resource model
Reimplemented from Varien_Object.
Definition at line 48 of file Flag.php.
00049 { 00050 $this->_init('core/flag'); 00051 }
getFlagData | ( | ) |
Retrieve flag data
Reimplemented in Mage_Catalog_Model_Product_Flat_Flag.
Definition at line 75 of file Flag.php.
00076 { 00077 if ($this->hasFlagData()) { 00078 return unserialize($this->getData('flag_data')); 00079 } else { 00080 return null; 00081 } 00082 }
loadSelf | ( | ) |
load self (load by flag code)
Definition at line 100 of file Flag.php.
00101 { 00102 if (is_null($this->_flagCode)) { 00103 Mage::throwException(Mage::helper('core')->__('Please define flag code.')); 00104 } 00105 00106 return $this->load($this->_flagCode, 'flag_code'); 00107 }
setFlagData | ( | $ | value | ) |
Set flag data
mixed | $value |
Definition at line 90 of file Flag.php.
$_flagCode = null [protected] |