Given the result of parsing a single FETCH response, construct a dict mapping response keys to response values.

ParametersfetchResponseListThe result of parsing a FETCH response with parseNestedParens and extracting just the response data (that is, just the part that comes after "FETCH"). The form of this input (and therefore the output of this method) is very disagreeable. A valuable improvement would be to enumerate the possible keys (representing them as structured objects of some sort) rather than using strings and tuples of tuples of strings and so forth. This would allow the keys to be documented more easily and would allow for a much simpler application-facing API (one not based on looking up somewhat hard to predict keys in a dict). Since fetchResponseList notionally represents a flattened sequence of pairs (identifying keys followed by their associated values), collapsing such complex elements of this list as ["BODY", ["HEADER.FIELDS", ["SUBJECT"]]] into a single object would also greatly simplify the implementation of this method.
ReturnsA dict of the response data represented by pairs. Keys in this dictionary are things like "RFC822.TEXT", "FLAGS", or ("BODY", ("HEADER.FIELDS", ("SUBJECT",))). Values are entirely dependent on the key with which they are associated, but retain the same structured as produced by parseNestedParens.
Function nativeStringResponse Undocumented
def nativeStringResponse(thing): (source)
Undocumented
API Documentation for Twisted, generated by pydoctor at 2020-03-20 23:54:06.