Lines Matching refs:value

26         value of the object are both quoted according to RFC5322 rules, but
163 value string and a dictionary as its arguments. The dictionary will
167 string value of the idealized representation of the data from the value.
181 setting them as the value of similarly named attributes) and remove all the
190 def __new__(cls, name, value):
192 cls.parse(value, kwds)
224 def _reconstruct(cls, value):
225 return str.__new__(cls, value)
238 The returned value is an ASCII-only string possibly containing linesep
256 def _reconstruct_header(cls_name, bases, value):
257 return type(cls_name, bases, {})._reconstruct(value)
266 def parse(cls, value, kwds):
267 kwds['parse_tree'] = cls.value_parser(value)
278 """Header whose value consists of a single timestamp.
283 The 'value' attribute is the normalized form of the timestamp,
293 def parse(cls, value, kwds):
294 if not value:
300 if isinstance(value, str):
301 kwds['decoded'] = value
303 value = utils.parsedate_to_datetime(value)
305 kwds['defects'].append(errors.InvalidDateDefect('Invalid date value or format'))
309 kwds['datetime'] = value
332 def value_parser(value):
333 address_list, value = parser.get_address_list(value)
334 assert not value, 'this should not happen'
338 def parse(cls, value, kwds):
339 if isinstance(value, str):
342 kwds['parse_tree'] = address_list = cls.value_parser(value)
353 if not hasattr(value, '__iter__'):
354 value = [value]
357 for item in value]
392 raise ValueError(("value of single address header {} is not "
409 def parse(cls, value, kwds):
410 kwds['parse_tree'] = parse_tree = cls.value_parser(value)
447 def parse(cls, value, kwds):
448 kwds['parse_tree'] = parse_tree = cls.value_parser(value)
456 utils._sanitize(value)
457 for name, value in parse_tree.params}
511 def parse(cls, value, kwds):
512 kwds['parse_tree'] = parse_tree = cls.value_parser(value)
531 def parse(cls, value, kwds):
532 kwds['parse_tree'] = parse_tree = cls.value_parser(value)
594 def __call__(self, name, value):
595 """Create a header instance for header 'name' from 'value'.
600 default_class, and passing the name and value to the constructed
604 return self[name](name, value)