'The name is returned unchanged.  If the input value has a \'name\'
attribute and it matches the name ignoring case, the value is returned
unchanged.  Otherwise the name and value are passed to header_factory
method, and the resulting custom header object is returned as the
value.  In this case a ValueError is raised if the input value contains
CR or LF characters.'

def header_store_parse(self, name, value):

    if (hasattr(value, 'name') and (value.name.lower() == name.lower())):
        return (name, value)
    if (isinstance(value, str) and (len(value.splitlines()) > 1)):
        raise ValueError('Header    values    may    not    contain    linefeed    or    carriage    return    characters')
    return (name, self.header_factory(name, value))
