src/xPDO/Om/xPDOObject.php
public function setDirty($key= '') {
        if (empty($key)) {
            foreach (array_keys($this->_fieldMeta) as $fIdx => $fieldKey) {
                $this->setDirty($fieldKey);
            }
        }
        else {
            $key = $this->getField($key, true);
            if ($key !== false) {
                $this->_dirty[$key] = $key;
                if (isset($this->_validated[$key])) unset($this->_validated[$key]);
            }
        }
    }
public function setDirty($key= '') {
        if (empty($key)) {
            foreach (array_keys($this->_fieldMeta) as $fIdx => $fieldKey) {
                $this->setDirty($fieldKey);
            }
        }
        else {
            $key = $this->getField($key, true);
            if ($key !== false) {
                $this->_dirty[$key] = $key;
                if (isset($this->_validated[$key])) unset($this->_validated[$key]);
            }
        }
    }
public function setDirty ( $ key = '' ) { if ( empty ( $ key ) ) { foreach ( array_keys ( $ this -> _fieldMeta ) as $ fIdx => $ fieldKey ) { $ this -> setDirty ( $ fieldKey ) ; } } else { $ key = $ this -> getField ( $ key , true ) ; if ( $ key !== false ) { $ this -> _dirty [ $ key ] = $ key ; if ( isset ( $ this -> _validated [ $ key ] ) ) unset ( $ this -> _validated [ $ key ] ) ; } } }
Add the field to a collection of field keys that have been modified.

This function also clears any validation flag associated with the field.

@param string $key The key of the field to set dirty.
Add the field to a collection of field keys that have been modified .