What mean this function in magento 2

I saw a function declared like this below.

<?php 
public function getFirstName():string
{
    return $this->firstName();    
}

why this :string is used and when I should use this.