[jdev] Simple Arbitrary Data Exchange

Kevin Smith kevin.smith at isode.com
Tue Sep 24 08:29:10 UTC 2019


On 24 Sep 2019, at 09:20, Dave Cridland <dave at cridland.net> wrote:
> 
> Is there interest amongst the developer community to provide a generalised, interoperable facility for the exchange of simple, arbitrary data between consenting entities? I'm calling this SADEX, but I'm really, really, not wed to this name.
> 
> The key here would be the API - you'd want to provide the equivalent of a function call such as:
> 
> void sadex_message(JID to, String type, String data)
> 
> You'd also need a callback for when you receive some, and perhaps an IQ form.

It’d depend how wed you are to exactly what you describe there. Swiften’s API would make more sense to do message->setSadexType(…) and message->setSadexData(), and a callback wouldn’t make much sense, you’d just message->getSadexType and message->getSadexData() (or maybe message->getSadex()->(get|set)(Data|Type)(). Not what you describe, but still equivalent to how subject/body work in the API, and I don’t see a problem with adding it.

/K



More information about the JDev mailing list