[Interest] Is there a QML way for doing web requests? Just for data, not for rendering.

Mark Gaiser markg85 at gmail.com
Thu Dec 28 16:23:26 CET 2017


On Thu, Dec 28, 2017 at 2:33 PM, Konstantin Tokarev <annulen at yandex.ru>
wrote:

>
>
> 28.12.2017, 15:23, "Mark Gaiser" <markg85 at gmail.com>:
>
> On Fri, Dec 22, 2017 at 11:19 PM, Mark Gaiser <markg85 at gmail.com> wrote:
>
> Hi,
>
> You know those fancy REST api's out there.
> How does one use them in QML?
>
> For websockets the answer is simple: QML WebSocket.
> But i didn't find a way to just do a web request to some url and get it's
> data, at least not a way that seems "QMLified".
>
> Sure, javascript can be used with it's XMLHttpRequest which will work just
> fine, but using it seems so.. not QML like. So is there a QML way to do
> such things?
>
>
> Best regards,
> Mark
>
>
> Bump..
>
>
> Did you see http://www.cutehacks.com/blog/2016/9/23/friendlier-network-
> requests-in-qml
> This is among first things that search engines show
>
> I apparently didn't do a good job at searching (which i did) :)
That looks like a really powerful "cURL for QML" api heavily inspired on
Javascript Promises.

I wouldn't use that directly in QML (it looks too low level for QML...) but
it can serve as base to implement some fancy models.
Thank you for that link!
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.qt-project.org/pipermail/interest/attachments/20171228/7639a237/attachment.html>


More information about the Interest mailing list