def parse_accept_header(value, cls=None):
    if cls is None:
        cls = Accept

    if not value:
        return cls(None)

    result = []
    for match in _accept_re.finditer(value):
        quality = match.group(2)
        if not quality:
            quality = 1
        else:
            quality = max(min(float(quality), 1), 0)
        result.append((match.group(1), quality))
    return cls(result)
Return the output tokens.
dataset/ETHPy150Open Eforcers/gae-flask-todo/lib/werkzeug/http.py/parse_accept_header--crossover with--dataset/ETHPy150Open jonathanslenders/ptpython/ptpython/prompt_style.py/PromptStyle.out_tokens