PDA

View Full Version : Possible for a signal to return a reply?



grantbj74
17th August 2012, 01:57
Hi,

I was just wondering if an emit signal can return a reply?

Thanks in advance,
Brendan

ChrisW67
17th August 2012, 03:13
No, signals are implemented as functions returning void. A signal can be connected to many receivers. Allowing a return value from the receiver(s) means the system has to have some form of arbitration system to determine which return value is returned via the single signal function. It also needs a return value when there is no receiver connected. Boost::signals does something like this, Qt does not.