Update current empty paex fields with values get from paex object of
parent of current main node.

@param bool $forceUpdate
@return true
491789
function updateFromParent( $forceUpdate = false )
    {
        $mainNode = eZContentObjectTreeNode::findMainNode( $this->attribute( 'contentobject_id' ), true );
        if ( !is_object( $mainNode ) )
        {
            eZDebug::writeDebug( 'mainNode not found', 'eZPaEx::updateFromParent' );
        }
        elseif ( $mainNode->attribute( 'depth' ) > 1 )
        {
            $parentMainNodeID = $mainNode->attribute('parent_node_id');
            $parentContentObject = eZContentObject::fetchByNodeID( $parentMainNodeID );
            $parentPaex = eZPaEx::getPaEx($parentContentObject->attribute('id'));
            if ( $parentPaex instanceof eZPaEx )
            {
                $paexUpdated = false;

                if ( !$this->hasRegexp() || $forceUpdate )
                {
                    $this->setAttribute( 'passwordvalidationregexp', $parentPaex->attribute( 'passwordvalidationregexp' ) );
                    $paexUpdated = true;
                }

                if ( !$this->hasLifeTime() || $forceUpdate )
                {
                    $this->setAttribute( 'passwordlifetime', $parentPaex->attribute( 'passwordlifetime' ) );
                    $paexUpdated = true;
                }

                if ( !$this->hasNotification() || $forceUpdate )
                {
                    $this->setAttribute( 'expirationnotification', $parentPaex->attribute( 'expirationnotification' ) );
                    $paexUpdated = true;
                }

                if ( $paexUpdated )
                {
                    eZDebug::writeDebug( 'Paex updated from parent', 'eZPaEx::updateFromParent' );
                    $this->store();
                }
            }
        }

        return true;
    }
1025676
public function postUpdate() {
        $Model = $this->Model;

        //determine which field from ExtJs to use as the primary key
        //may replace with $id = Input::get('id');
        $id = $this->getKeyFromInput();

        //get record
        $record = $Model::findOrFail($id);
        $record->update(Input::all());

        return ( $record->errors )
            ? $this->failure($record, $record->getErrors())
            : $this->success($record);

    }
1372480
public function getManageUpdate($full = false)
    {
        $uri = 'manage.update';
        $uriData = [];
        if ($full) {
            $uriData['full'] = true;
        }

        try {
            $response = $this->_request(
                [
                    'uri' => $uri,
                    'type' => 'get',
                    'data' => []
                ]
            );
        } catch (\Exception $e) {
            throw new InvalidException($e->getMessage());
        }

        return $response->getBody()->getContents();
    }
656950
public function update()
    {
        if ($this->newVersionAvailable === false
        || (!is_bool($this->newVersionAvailable) && !$this->hasUpdate())) {
            return false;
        }
        $this->backupPhar();
        $this->downloadPhar();
        $this->replacePhar();
        return true;
    }
1042876
public static function Updatable ($name, $extension = null, $forced_obtain = false) {
		$access_lv = static::GetDetail($name, $extension, $forced_obtain)['access'];
		if ($access_lv === static::PHP_INI_USER) {
			return true;
		}
		if ($access_lv === static::PHP_INI_ALL) {
			return true;
		}
		return false;
	}
338821
public function beforeDelete( $forced = false )
  {
    try {

        if($this->resourcenodes){
            $this->resourcenodes->each(function($node){
                $node->delete();
            });
        }
    } catch(Execption $e) {}

    return true;
  }
224547
public function update($itemData, $createIfAbsent = false)
    {
        $newData = $this->preUpdate($itemData, $createIfAbsent);
        $result = $this->dataStore->update($newData, $createIfAbsent);

        return $this->postUpdate($result, $newData, $createIfAbsent);
    }
334904
def update(self, sha, force=False):
        
        data = {'sha': sha, 'force': force}
        json = self._json(self._patch(self._api, data=dumps(data)), 200)
        if json:
            self._update_(json)
            return True
        return False
182502
public function listing($forceUpdate = false, array $params = [])
    {
        if (empty($this->users) || $forceUpdate) {
            $this->all($params);
        }
        $ret = [];
        if (is_array($this->users) && isset($this->users['users'])) {
            foreach ($this->users['users'] as $e) {
                $ret[$e['login']] = (int) $e['id'];
            }
        }

        return $ret;
    }
55690
private function update ()
	{
		$this->before_update();

		$statement = 'UPDATE ' . static::$table_name . ' SET ';

		$sets = [];
		$values = [];

		foreach ($this->storage as $key => $value) {
			if ($value !== null) {
				$sets[] = $this->db->quote_column($key) . ' = ?';
				$values[] = $value;
			}
		}

		$statement .= implode(', ', $sets);

		$pk = $this->primary_key_condition();

		$statement .= ' WHERE ' . $pk->statement;

		$values = array_merge($values, $pk->values->getArrayCopy());

		$result = $this->db->query($statement, $values, 'multi', null, false);

		$this->stored = true;
		$this->updated = false;

		$this->after_update();

		return true;
	}
470746
public function getValuesChangeset($forceRecompute = false)
    {
        if (null === $this->valuesChangeset || $forceRecompute) {
            $this->computeValuesChangeset();
        }

        return $this->valuesChangeset;
    }
1112108
final public function update($properties=NULL) {
		
		// hook for tasks to be executed before creation
		$this->beforeUpdate();
		
		$app	= Application::getInstance();
		$class	= get_called_class();
		$binds	= static::getBinds();
		
		// if property list is empty, will include all
		$properties	= (array)$properties;
		if (!count($properties)) {
			$properties = array_keys($class::getBinds());
		}
		
		$logParam = $this->getKeyForEventlog();

		// require table primary key and force its assign
		if ($this->areKeysPopulated()) {

			// set an object with fields to update
			$dbObj = $this->prepareData($properties);

			// force to array
			$key = (array)$this->keyProperties;

			$dbKey = new \stdClass();

			// set the table key with values
			foreach ($key as $k) {
				
				// get object property value
				$dbKey->{$binds[$k]} = $this->$k;
					
			}
				
			$res = (bool)$this->db->updateObject($class::TABLE_NAME, $dbObj, $dbKey);
			
			$app->logEvent('Updated ' . $class . ' object with ' . $logParam);

		// object is not populated
		} else {

			$res = FALSE;
			$app->logError('The ' . $class . ' object with ' . $logParam . ' cannot be updated');

		}
		
		// hook for tasks to be executed after creation
		$this->afterUpdate();
		
		return $res;
		
	}
287697
public function update() {
        $this->isNewRecord = false;
        if ($this->usesTimestamps()) {
            $this->updateTimestamps();
        }
        $this->invoke(self::BEFORE_UPDATE, [$this]);
        if (!$this->validate()) {
            return false;
        }
        $query = $this->getPrimaryKeyQuery();
        if (empty($query)) {
            $this->setError('pk', 'ERROR PK!');
            return false;
        }
        $data = $this->_getRealFields();
        if (empty($data)) {
            return true;
        }
        $row = $query
            ->update($data);
        if (!empty($row)) {
            $this->setOldAttribute();
        } else {
            $this->setError('data', 'Data is not change!');
        }
        $this->invoke(self::AFTER_UPDATE, [$this]);
        return $row;
    }
1174075
public function getUpdates($force = FALSE) {
		if (!$force) {
			$result = $this->cache->get('updates');
			if ($result) {
				return $result;
			}
		}

		// Make sure we're logged in and have a valid access token.
		if (!$this->auth_token || !$this->username) {
			return FALSE;
		}

		$timestamp = parent::timestamp();
		$result = parent::post(
			'/all_updates',
			array(
				'timestamp' => $timestamp,
				'username' => $this->username,
			),
			array(
				$this->auth_token,
				$timestamp,
			)
		);

		if (!empty($result->updates_response)) {
			$this->auth_token = $result->updates_response->auth_token;
			$this->cache->set('updates', $result->updates_response);
			return $result->updates_response;
		}

		return $result;
	}
360981
protected function _reindex($force = false)
    {
        $id = $this->getMimeId();

        if (($this->_status & self::STATUS_REINDEX) ||
            ($force && is_null($id))) {
            $this->buildMimeIds(
                is_null($id)
                    ? (($this->getPrimaryType() === 'multipart') ? '0' : '1')
                    : $id
            );
        }
    }
785635
function onPublish( $contentObjectAttribute, $contentObject, $publishedNodes )
    {
        eZDebug::writeDebug( 'Start', __METHOD__ );
        $paex = $contentObjectAttribute->content();
        if ( !$paex instanceof eZPaEx )
        {
            return true;
        }

        // Update empty paex data from parent paex
        // NOTE: if the current user don't have permission to edit paex data, and is
        // creating a new object (publishing version 1), force paex object update
        // to get values set in parent
        if ( !$paex->canEdit() && $contentObject->attribute( 'current_version' ) == 1 )
            $paex->updateFromParent( true );
        else
            $paex->updateFromParent();

        eZDebug::writeDebug( 'End', __METHOD__ );
        return true;
    }
1136221
public function update()
    {
        // copy the code into memory
        $backup = file($this->reflection->getFileName());

        list($preamble, $class) = $this->splitClassFile($backup);
        $preamble = $this->stripOutExistingDocBlock($preamble);
        $preamble .= $this->buildUpdatedDocBlock();

        if ($this->writeClassFile(implode(PHP_EOL, [$preamble, $class]))
            && $this->commandLineLint($this->reflection->getFileName())
        ) {
            return true;
        }

        $this->writeClassFile(implode('', $backup));
        return false;
    }