Create hash string from current class properties and itself values.
This method is good stuff for caching dynamic instances
@return string|null
180285
public function createStringClassSnapshotHash()
    {
        $hash = null;
        foreach ($this as $property => $value) {
            $hash = md5($hash . $property . '=' . $value);
        }
        return $hash;
    }
805051
public static function passwordReHash($password = '', $hash = '')
    {
        if (self::verifyPassword($password, $hash)) {
            if (password_needs_rehash($hash, self::ALGORITHM_DEFAULT)) {
                return self::createPassword($password);
            }
        }

        return NULL;
    }
805056
public function getHash()
    {
        if ($this->hash === null) {
            $this->hash = sha1_file($this->getLocalPath());
        }

        return $this->hash;
    }
1249836
protected function getHash()
    {
        return md5(sprintf('%s %s %s %s',
            $this->getMethod(),
            $this->getPath(),
            json_encode($this->getHeaders()),
            json_encode($this->getQueryString())
        ));
    }
846868
public function generateCacheId()
    {
        if (!$this->getCurrentView()) {
            throw new \Exception(sprintf(
                'Cannot generate an hash for widget %s if currentView is not defined.',
                $this->getId()
            ));
        }

        return sprintf(
            '%s-%s-%s',
            $this->getId(),
            $this->getUpdatedAt()->getTimestamp(),
            $this->getCurrentView()->getReference()->getId()
        );
    }
805539
public function getHashCode()
    {
        if ($this->dirty) {
            $this->hash = md5($this->title . $this->autoFilter . ($this->protection->isProtectionEnabled() ? 't' : 'f') . __CLASS__);
            $this->dirty = false;
        }
        return $this->hash;
    }
602844
private function hash()
    {
        $this->hash = md5($this->uri . serialize($this->headers) . serialize($this->payload));

        return $this;
    }
1069246
public function replaceHash()
    {
        $currentHash = $this->cacheBuster->getHash();
        $hash = $this->cacheBuster->generateHash();
        $this->writeHash($currentHash, $hash);
        $this->cacheBuster->setHash($hash);
        return $hash;
    }
712292
public function generateHashId($attributes)
    {
        $hashable_string = $this->getHashableString($attributes);
        if($hashable_string) return $this->hash($hashable_string);
        return null;
    }
1057599
public function getHash(): string
    {
        $init = $this->pos;
        \fseek($this->fp, 0, SEEK_SET);

        // Create a hash context:
        $h = \sodium_crypto_generichash_init(
            $this->hashKey,
            \SODIUM_CRYPTO_GENERICHASH_BYTES_MAX
        );
        for ($i = 0; $i < $this->stat['size']; $i += self::CHUNK) {
            if (($i + self::CHUNK) > $this->stat['size']) {
                $c = \fread($this->fp, ((int) $this->stat['size'] - $i));
            } else {
                $c = \fread($this->fp, self::CHUNK);
            }
            if (!\is_string($c)) {
                // @codeCoverageIgnoreStart
                throw new FileError('Could not read file');
                // @codeCoverageIgnoreEnd
            }
            \sodium_crypto_generichash_update($h, $c);
        }
        // Reset the file pointer's internal cursor to where it was:
        \fseek($this->fp, $init, SEEK_SET);
        return \sodium_crypto_generichash_final($h);
    }
1284864
public function hash(string $string): Hash {
        $hash = new Hash();
        $hash->setAlgorithm($this->getAlgorithm());
        $value = hash($this->getAlgorithm(), $string, true);
        $hash->setValue($value);
        return $hash;
    }
897773
private function getHash()
	{
		if($this->_hash===null)
			$this->_hash=sha1(serialize($this));
		return $this->_hash;
	}
872741
public static function Serialize($hash){
		if(is_null($hash))
			return null;
		$res=Array();
		$keys=array_keys($hash);
		$i=-1;
		$len=sizeof($keys);
		while(++$i<$len)
			$res[]=new PhpWsdlHash($keys[$i],$hash[$keys[$i]]);
		return $res;
	}
416873
public function getHash()
    {
        $hash = array();

        // expression
        $hash[] = json_encode($this->expression->toArray());

        // sorts
        if (!empty($this->sort)) {
            $sort = $this->sort;
            ksort($sort);
            $hash[] = implode('', array_merge(array_keys($sort), array_values($sort)));
        }

        // fields
        if (!empty($this->projection)) {
            $fields = $this->projection;
            ksort($fields);
            $hash[] = implode('', array_merge(array_keys($fields), array_values($fields)));
        }

        // skip and limit
        $hash[] = $this->skip;
        $hash[] = $this->limit;

        // get hash
        return md5(implode(':', $hash));
    }
26027
private function _generateKey()
    {
        if ($this->_key == '') {
            $this->_key = pack(
                'H*',
                hash('SHA256', md5(uniqid()))
            );
        }

        return $this->_key;
    }
405264
public function generateHash(): string
    {
        $h = sprintf('%s%s%s', (string)$this->getIdentificator(), $this->getExpiration(), $this->getSecret());
        $h = md5($h, true);
        $h = self::base64url_encode($h);
        return $h;
    }
1201688
public function buildHash(): string
    {
        $hash = Crypt::hash(serialize($this), true);
        $this->lastBuildedHash = $hash;
        return $hash;
    }