comparison src/tools/xml_tools.py @ 1903:29564cec913f

plugin XEP-0060: service, node and uri are added to metadata when doing a getItems
author Goffi <goffi@goffi.org>
date Wed, 09 Mar 2016 16:59:29 +0100
parents c271087d2020
children 2daf7b4c6756
comparison
equal deleted inserted replaced
1902:085f29c20f7e 1903:29564cec913f
37 SAT_FORM_PREFIX = "SAT_FORM_" 37 SAT_FORM_PREFIX = "SAT_FORM_"
38 SAT_PARAM_SEPARATOR = "_XMLUI_PARAM_" # used to have unique elements names 38 SAT_PARAM_SEPARATOR = "_XMLUI_PARAM_" # used to have unique elements names
39 html_entity_re = re.compile(r'&([a-zA-Z]+?);') 39 html_entity_re = re.compile(r'&([a-zA-Z]+?);')
40 XML_ENTITIES = ('quot', 'amp', 'apos', 'lt', 'gt') 40 XML_ENTITIES = ('quot', 'amp', 'apos', 'lt', 'gt')
41 41
42 # TODO: move XMLUI stuff in a separate module
42 43
43 # Helper functions 44 # Helper functions
44 45
45 def _dataFormField2XMLUIData(field, read_only=False): 46 def _dataFormField2XMLUIData(field, read_only=False):
46 """Get data needed to create an XMLUI's Widget from Wokkel's data_form's Field. 47 """Get data needed to create an XMLUI's Widget from Wokkel's data_form's Field.