src/Traits/PathTrait.php
private function myFilenameToString(?callable $stringEncoder = null): string
    {
        if ($this->myFilename === null) {
            return '';
        }

        if ($stringEncoder !== null) {
            return $stringEncoder($this->myFilename);
        }

        return $this->myFilename;
    }
private function myFilenameToString(?callable $stringEncoder = null): string
    {
        if ($this->myFilename === null) {
            return '';
        }

        if ($stringEncoder !== null) {
            return $stringEncoder($this->myFilename);
        }

        return $this->myFilename;
    }
private function myFilenameToString ( ? callable $ stringEncoder = null ) : string { if ( $ this -> myFilename === null ) { return '' ; } if ( $ stringEncoder !== null ) { return $ stringEncoder ( $ this -> myFilename ) ; } return $ this -> myFilename ; }
Returns the filename as a string.

@param callable|null $stringEncoder The string encoding function or null if parts should not be encoded.

@return string The filename as a string.
Returns the filename as a string .