示例#1
0
文件: part.py 项目: hartym/flanker
 def add(self, key, value):
     MimeHeaders.add(self, key, value)
     self._m[key] = headers.to_mime(normalize(key), remove_newlines(value))
示例#2
0
文件: part.py 项目: hartym/flanker
 def __delitem__(self, key):
     MimeHeaders.__delitem__(self, key)
     del self._m[key]
示例#3
0
文件: part.py 项目: hartym/flanker
 def prepend(self, key, value):
     MimeHeaders.prepend(self, key, value)
     self._m._headers.insert(0, (normalize(key), remove_newlines(value)))
示例#4
0
文件: part.py 项目: hartym/flanker
 def __init__(self, message):
     MimeHeaders.__init__(self, [(k, _try_decode(k, v))
                                 for k, v in list(message.items())])
     self._m = message
示例#5
0
文件: part.py 项目: hartym/flanker
 def __setitem__(self, key, value):
     MimeHeaders.__setitem__(self, key, value)
     del self._m[key]
     self._m[key] = remove_newlines(value)
示例#6
0
 def add(self, key, value):
     MimeHeaders.add(self, key, value)
     self._m[key] = headers.to_mime(normalize(key), remove_newlines(value))
示例#7
0
 def prepend(self, key, value):
     MimeHeaders.prepend(self, key, value)
     self._m._headers.insert(0, (normalize(key), remove_newlines(value)))
示例#8
0
 def __delitem__(self, key):
     MimeHeaders.__delitem__(self, key)
     del self._m[key]
示例#9
0
 def __setitem__(self, key, value):
     MimeHeaders.__setitem__(self, key, value)
     del self._m[key]
     self._m[key] = remove_newlines(value)
示例#10
0
 def __init__(self, message):
     MimeHeaders.__init__(self, [(k, _try_decode(k, v))
                                 for k, v in message.items()])
     self._m = message