Registers a function to respond to XML-RPC requests. The optional name argument can be used to set a Unicode name for the function.
(self, function=None, name=None)
| 207 | self.allow_dotted_names = allow_dotted_names |
| 208 | |
| 209 | def register_function(self, function=None, name=None): |
| 210 | """Registers a function to respond to XML-RPC requests. |
| 211 | |
| 212 | The optional name argument can be used to set a Unicode name |
| 213 | for the function. |
| 214 | """ |
| 215 | # decorator factory |
| 216 | if function is None: |
| 217 | return partial(self.register_function, name=name) |
| 218 | |
| 219 | if name is None: |
| 220 | name = function.__name__ |
| 221 | self.funcs[name] = function |
| 222 | |
| 223 | return function |
| 224 | |
| 225 | def register_introspection_functions(self): |
| 226 | """Registers the XML-RPC introspection methods in the system |