Mercurial > libervia-backend
comparison libervia/backend/plugins/plugin_xep_0166/models.py @ 4115:0da563780ffc
plugin XEP-0167, XEP-0353: handle ringing:
- add a `jingle_preflight_info` method in the Jingle Application model to handle this kind
of information
- XEP-0353 is calling `jingle_preflight_info` when a `ringing` message is received
- XEP-0167 use this information to send a `ringing` info to frontends
author | Goffi <goffi@goffi.org> |
---|---|
date | Wed, 16 Aug 2023 18:33:28 +0200 |
parents | bc60875cb3b8 |
children | e11b13418ba6 |
comparison
equal
deleted
inserted
replaced
4114:79ec7d7beef3 | 4115:0da563780ffc |
---|---|
38 description_elt: domish.Element | 38 description_elt: domish.Element |
39 ) -> None: | 39 ) -> None: |
40 """Called when preparation steps are needed by a plugin | 40 """Called when preparation steps are needed by a plugin |
41 | 41 |
42 Notably used by XEP-0353 when a initiation message is received | 42 Notably used by XEP-0353 when a initiation message is received |
43 """ | |
44 pass | |
45 | |
46 @abc.abstractmethod | |
47 async def jingle_preflight_info( | |
48 self, | |
49 client: SatXMPPEntity, | |
50 session: dict, | |
51 info_type: str, | |
52 info_data: dict|None = None | |
53 ) -> None: | |
54 """Called when we have new information during preflight | |
55 | |
56 Notably used by XEP-0353 to signal ringing | |
43 """ | 57 """ |
44 pass | 58 pass |
45 | 59 |
46 @abc.abstractmethod | 60 @abc.abstractmethod |
47 async def jingle_preflight_cancel( | 61 async def jingle_preflight_cancel( |