code: def filter(self, media_type, **params):
          
          mtype, msubtype = self._split_media_type(media_type)
          for x in self.__iter__():
              # all the params have to match to make the media type valid
              matched = True
              for k, v in params.items():
                  if x[2].get(k, None) != v:
                      matched = False
                      break
  
              if matched:
                  if x[0][0] == '*':
                      if x[0][1] == '*':
                          yield x
  
                      elif x[0][1] == msubtype:
                          yield x
  
                  elif mtype == '*':
                      if msubtype == '*':
                          yield x
  
                      elif x[0][1] == msubtype:
                          yield x
  
                  elif x[0][0] == mtype:
                      if msubtype == '*':
                          yield x
  
                      elif x[0][1] == '*':
                          yield x
  
                      elif x[0][1] == msubtype:
                          yield x
docs: iterate all the accept media types that match media_type
  
          media_type -- string -- the media type to filter by
          **params -- dict -- further filter by key: val
  
          return -- generator -- yields all matching media type info things