Interceptor in QT?
-
Hi,
I got to know that in java spring framework etc. We have interceptors which help process the request & response.In QT, do we have anything similar that can be used.
Currently for making REST api calls in my application i am making use of QNAM.Thanks
-
@Rizwan94 said in Interceptor in QT?:
I got to know that in java spring framework etc. We have interceptors which help process the request & response.
In QT, do we have anything similar that can be used.
Qt uses signals and slots: https://doc.qt.io/qt-5/signalsandslots.html
Currently for making REST api calls in my application i am making use of QNAM.
When you call
get()
orpost()
, QNAM returns aQNetworkReply
object. Connect theQNetworkReply::finished()
signal to a slot to process the reply. Remember to delete theQNetworkReply
when you have finished processing.