code: def _Open(self, path_spec=None, mode='rb'):
      
      if not path_spec:
        raise ValueError('Missing path specification.')
  
      store_index = vshadow.VShadowPathSpecGetStoreIndex(path_spec)
      if store_index is None:
        raise errors.PathSpecError(
            'Unable to retrieve store index from path specification.')
  
      self._file_system = resolver.Resolver.OpenFileSystem(
          path_spec, resolver_context=self._resolver_context)
      vshadow_volume = self._file_system.GetVShadowVolume()
  
      if (store_index < 0 or
          store_index >= vshadow_volume.number_of_stores):
        raise errors.PathSpecError((
            'Unable to retrieve VSS store: {0:d} from path '
            'specification.').format(store_index))
  
      vshadow_store = vshadow_volume.get_store(store_index)
      if not vshadow_store.has_in_volume_data():
        raise IOError((
            'Unable to open VSS store: {0:d} without in-volume stored '
            'data.').format(store_index))
  
      self._vshadow_store = vshadow_store
docs: Opens the file-like object defined by path specification.
  
      Args:
        path_spec (PathSpec): path specification.
        mode (Optional[str]): file access mode.
  
      Raises:
        AccessError: if the access to open the file was denied.
        IOError: if the file-like object could not be opened.
        OSError: if the file-like object could not be opened.
        PathSpecError: if the path specification is incorrect.
        ValueError: if the path specification is invalid.