src/I18n/GettextMessageSource.php
protected function getGettextFile($messageFile)
    {
        if (isset($this->_gettextFiles[$messageFile])) {
            return $this->_gettextFiles[$messageFile];
        }
        if (!is_file($messageFile)) {
            return null;
        }
        if ($this->useMoFile) {
            $gettextFile = new GettextMoFile(['filePath' => $messageFile, 'useBigEndian' => $this->useBigEndian]);
        } else {
            $gettextFile = new GettextPoFile(['filePath' => $messageFile]);
        }
        return $this->_gettextFiles[$messageFile] = $gettextFile;
    }
protected function getGettextFile($messageFile)
    {
        if (isset($this->_gettextFiles[$messageFile])) {
            return $this->_gettextFiles[$messageFile];
        }
        if (!is_file($messageFile)) {
            return null;
        }
        if ($this->useMoFile) {
            $gettextFile = new GettextMoFile(['filePath' => $messageFile, 'useBigEndian' => $this->useBigEndian]);
        } else {
            $gettextFile = new GettextPoFile(['filePath' => $messageFile]);
        }
        return $this->_gettextFiles[$messageFile] = $gettextFile;
    }
Get gettext file class
@param string $messageFile
@return GettextFile|null