PhpOffice\PhpPresentation\Slide\AbstractSlide::getHashCode PHP Метод

getHashCode() публичный Метод

Get hash code
public getHashCode ( ) : string
Результат string Hash code
    public function getHashCode()
    {
        return md5($this->identifier . __CLASS__);
    }

Usage Example

Пример #1
0
 /**
  * Get index for slide
  *
  * @param  \PhpOffice\PhpPresentation\Slide\AbstractSlide $slide
  * @return int
  * @throws \Exception
  */
 public function getIndex(Slide\AbstractSlide $slide)
 {
     $index = null;
     foreach ($this->slideCollection as $key => $value) {
         if ($value->getHashCode() == $slide->getHashCode()) {
             $index = $key;
             break;
         }
     }
     return $index;
 }