Branko over at activecodeline.com found some interesting methods that are not even used in the current 1.2.1.2 release of Magento. You can find them in lib/Varien/Object.php, Is it possibly garbage collection/cleanup for 3rd modules in the future?
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 | <?php /** * Enter description here... * * @param string $field * @return boolean */ public function isDirty($field=null) { if (empty($this->_dirty)) { return false; } if (is_null($field)) { return true; } return isset($this->_dirty[$field]); } /** * Enter description here... * * @param string $field * @param boolean $flag * @return Varien_Object */ public function flagDirty($field, $flag=true) { if (is_null($field)) { foreach ($this->getData() as $field=>$value) { $this->flagDirty($field, $flag); } } else { if ($flag) { $this->_dirty[$field] = true; } else { unset($this->_dirty[$field]); } } return $this; } ?> |
Magento isDirty | ActiveCodeline.
Possibly Related Posts:
- Magento Commerce Error Reporting Tip
- Eclipse + ZendStudio + ZendServer + Android SDK = Awesome IDE
- Magento: Paypal Standard IPN Double Totals Bug 1.3.2.3 + fix
- iPhone Magento theme compatible with Android
- Magento Tutorial Video: Display Product Images in Blocks and Pages