def proppatch(<EOL>self, path, set_props=None, remove_props=None, namespace="<STR_LIT>", headers=None<EOL>):
root = ElementTree.Element("<STR_LIT>")<EOL>if set_props is not None:<EOL><INDENT>prop_set = ElementTree.SubElement(root, "<STR_LIT>")<EOL>for p in set_props:<EOL><INDENT>prop_prop = ElementTree.SubElement(prop_set, "<STR_LIT>")<EOL>object_to_etree(prop_prop, p, namespace=namespace)<EOL><DEDENT><DEDENT>if remove_props is not None:<EOL><INDENT>prop_remove = ElementTree.SubElement(root, "<STR_LIT>")<EOL>for p in remove_props:<EOL><INDENT>prop_prop = ElementTree.SubElement(prop_remove, "<STR_LIT>")<EOL>object_to_etree(prop_prop, p, namespace=namespace)<EOL><DEDENT><DEDENT>tree = ElementTree.ElementTree(root)<EOL>body = self._tree_to_binary_body(tree)<EOL>if headers is None:<EOL><INDENT>headers = {}<EOL><DEDENT>headers["<STR_LIT:Content-Type>"] = '<STR_LIT>'<EOL>self._request("<STR_LIT>", path, body=body, headers=headers)<EOL>
Patch properties on a DAV resource.

        If namespace is not specified, the DAV namespace is used for all properties.