parameters: (response)
return_statement: return link_object
docstring: Parse a github 'Link' header into an object with paginated links.
docstring_summary: Parse a github 'Link' header into an object with paginated links.
docstring_tokens: Parse a github Link header into an object with paginated links .
function: def _parse_link(response):
          """Parse a github 'Link' header into an object with paginated links."""
          link_object = {}
  
          if not response.headers["Link"]:
              return link_object
  
          links = response.headers["Link"].split(",")
          for link in links:
              link_parts = link.split(";")
              link_type = link_parts[1].replace("rel=", "").strip(" \"")
              link_address = link_parts[0].strip("<> ")
              link_object[link_type] = link_address
  
          return link_object
function_tokens: def _parse_link ( response ) : link_object = { } if not response . headers [ "Link" ] : return link_object links = response . headers [ "Link" ] . split ( "," ) for link in links : link_parts = link . split ( ";" ) link_type = link_parts [ 1 ] . replace ( "rel=" , "" ) . strip ( " \"" ) link_address = link_parts [ 0 ] . strip ( "<> " ) link_object [ link_type ] = link_address return link_object