code: def requirement_info(self):
          # type: () -> Tuple[Optional[S], Tuple[Optional[S], ...], Optional[S]]
          
  
          # Direct URLs can be converted to packaging requirements directly, but
          # only if they are `file://` (with only two slashes)
          name = None  # type: Optional[S]
          extras = ()  # type: Tuple[Optional[S], ...]
          url = None  # type: Optional[STRING_TYPE]
          # if self.is_direct_url:
          if self._name:
              name = canonicalize_name(self._name)
          if self.is_file or self.is_url or self.is_path or self.is_file_url or self.is_vcs:
              url = ""
              if self.is_vcs:
                  url = self.url if self.url else self.uri
                  if self.is_direct_url:
                      url = self.link.url_without_fragment
              else:
                  if self.link:
                      url = self.link.url_without_fragment
                  elif self.url:
                      url = self.url
                      if self.ref:
                          url = "{0}@{1}".format(url, self.ref)
                  else:
                      url = self.uri
              if self.link and name is None:
                  self._name = self.link.egg_fragment
                  if self._name:
                      name = canonicalize_name(self._name)
          return name, extras, url
docs: Generates a 3-tuple of the requisite *name*, *extras* and *url* to generate a
          :class:`~packaging.requirements.Requirement` out of.
  
          :return: A Tuple of an optional name, a Tuple of extras, and an optional URL.
          :rtype: Tuple[Optional[S], Tuple[Optional[S], ...], Optional[S]]