def _GetStat(self):
    cpio_archive_file_entry = self.GetCPIOArchiveFileEntry()
    if not self._is_virtual and cpio_archive_file_entry is None:
      raise errors.BackEndError(
          u'Missing CPIO archive file entry in non-virtual file entry.')

    stat_object = vfs_stat.VFSStat()

    # File data stat information.
    stat_object.size = getattr(cpio_archive_file_entry, u'data_size', None)

    # Date and time stat information.
    stat_object.mtime = getattr(
        cpio_archive_file_entry, u'modification_time', None)

    # Ownership and permissions stat information.
    mode = getattr(cpio_archive_file_entry, u'mode', 0)
    stat_object.mode = stat.S_IMODE(mode)
    stat_object.uid = getattr(
        cpio_archive_file_entry, u'user_identifier', None)
    stat_object.gid = getattr(
        cpio_archive_file_entry, u'group_identifier', None)

    # File entry type stat information.

    # The stat info member st_mode can have multiple types e.g.
    # LINK and DIRECTORY in case of a symbolic link to a directory
    # dfVFS currently only supports one type so we need to check
    # for LINK first.
    if stat.S_ISLNK(mode):
      stat_object.type = stat_object.TYPE_LINK
    # The root file entry is virtual and should have type directory.
    elif self._is_virtual or stat.S_ISDIR(mode):
      stat_object.type = stat_object.TYPE_DIRECTORY
    elif stat.S_ISREG(mode):
      stat_object.type = stat_object.TYPE_FILE
    elif stat.S_ISCHR(mode) or stat.S_ISBLK(mode):
      stat_object.type = stat_object.TYPE_DEVICE
    elif stat.S_ISFIFO(mode):
      stat_object.type = stat_object.TYPE_PIPE
    elif stat.S_ISSOCK(mode):
      stat_object.type = stat_object.TYPE_SOCKET

    return stat_object
Retrieves the stat object.
dataset/ETHPy150Open log2timeline/dfvfs/dfvfs/vfs/cpio_file_entry.py/CPIOFileEntry._GetStat