@classmethod
  def Open(cls, fd, component, pathspec=None, progress_callback=None,
           full_pathspec=None):
    # The handler for this component
    try:
      handler = VFS_HANDLERS[component.pathtype]
    except KeyError:
      raise IOError(
          "VFS handler %d not supported." % component.pathtype)

    # We will not do any case folding unless requested.
    if component.path_options == rdf_paths.PathSpec.Options.CASE_LITERAL:
      return handler(base_fd=fd, pathspec=component)

    path_components = client_utils.LocalPathToCanonicalPath(component.path)
    path_components = ["/"] + filter(None, path_components.split("/"))
    for i, path_component in enumerate(path_components):
      try:
        if fd:
          new_pathspec = fd.MatchBestComponentName(path_component)
        else:
          new_pathspec = component
          new_pathspec.path = path_component

        # The handler for this component
        try:
          handler = VFS_HANDLERS[new_pathspec.pathtype]
        except KeyError:
          raise IOError(
              "VFS handler %d not supported." % new_pathspec.pathtype)

        fd = handler(base_fd=fd, pathspec=new_pathspec,
                     full_pathspec=full_pathspec,
                     progress_callback=progress_callback)
      except IOError:
        # Can not open the first component, we must raise here.
        if i <= 1:
          raise IOError("File not found")

        # Insert the remaining path at the front of the pathspec.
        pathspec.Insert(0, path=utils.JoinPath(*path_components[i:]),
                        pathtype=rdf_paths.PathSpec.PathType.TSK)
        break

    return fd
pragma_args : pragma_arg COMMA pragma_args
dataset/ETHPy150Open google/grr/grr/client/vfs.py/VFSHandler.Open--crossover with--dataset/ETHPy150Open nucleic/enaml/enaml/core/parser.py/p_pragma_args1