def _add_propstat_to(element, tag, status_number):
 propstat = ET.Element(_tag('D', 'propstat'))
 element.append(propstat)
 prop = ET.Element(_tag('D', 'prop'))
 propstat.append(prop)
 clark_tag = (tag if ('{' in tag) else _tag(*tag.split(':', 1)))
 prop_tag = ET.Element(clark_tag)
 prop.append(prop_tag)
 status = ET.Element(_tag('D', 'status'))
 status.text = _response(status_number)
 propstat.append(status)

def _add_propstat_to ( element , tag , status_number ) : propstat = ET . Element ( _tag ( 'D' , 'propstat' ) ) element . append ( propstat ) prop = ET . Element ( _tag ( 'D' , 'prop' ) ) propstat . append ( prop ) clark_tag = ( tag if ( '{' in tag ) else _tag ( * tag . split ( ':' , 1 ) ) ) prop_tag = ET . Element ( clark_tag ) prop . append ( prop_tag ) status = ET . Element ( _tag ( 'D' , 'status' ) ) status . text = _response ( status_number ) propstat . append ( status )
add a propstat response structure to an element .