|
SplObjectStorage::getHash(Информация о версии неизвестна, возможно, только в SVN) SplObjectStorage::getHash — Calculate a unique identifier for the contained objects Описание
public string SplObjectStorage::getHash
( string $object
)
The function calculates an identifier for the objects added to this SplObjectStorage object. The implementation in SplObjectStorage returns the same value as spl_object_hash(). This identifier must be unique among the objects contained. This means this object will never contain more than one object with the same identifier. As such, it can be used to implement a set (a collection of unique values) where the quality of an object being unique is determined by the value returned by this function being unique. Список параметров
Возвращаемые значенияA string with the calculated identifier. An exception is thrown if any other type is returned. Примеры
Пример #1 SplObjectStorage::getHash() example
<?php Результатом выполнения данного примера будет что-то подобное: 2 3 |
|