lib/bagit_manifest.php
public function update($fileList)
    {
        $csums = array();

        foreach ($fileList as $file) {
            if (file_exists($file)) {
                $hash = $this->calculateHash($file);
                $csums[$this->_makeRelative($file)] = $hash;
            }
        }

        $this->data = $csums;

        $this->write();

        return $csums;
    }
public function update($fileList)
    {
        $csums = array();

        foreach ($fileList as $file) {
            if (file_exists($file)) {
                $hash = $this->calculateHash($file);
                $csums[$this->_makeRelative($file)] = $hash;
            }
        }

        $this->data = $csums;

        $this->write();

        return $csums;
    }
public function update ( $ fileList ) { $ csums = array ( ) ; foreach ( $ fileList as $ file ) { if ( file_exists ( $ file ) ) { $ hash = $ this -> calculateHash ( $ file ) ; $ csums [ $ this -> _makeRelative ( $ file ) ] = $ hash ; } } $ this -> data = $ csums ; $ this -> write ( ) ; return $ csums ; }
This updates the data in the manifest from the files passed in.

@param array $fileList A list of files to include in the manifest.

@return array The new hash mapping from those files.
This updates the data in the manifest from the files passed in .