I need to call this external command “qconf” from my application without freezing it where
queueList = ["all.q","a1.q","a2.q","a3.q"]
I found that this can be done using threads. How ?
Is there another way
command is
qconf -sq all.q
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Try something like this. QtConcurrent will optimize the thread count.
Edit
If you want result from every process you need the mapped function
QFuture<T> mapped ( const Sequence & sequence, MapFunction function )and executeInProcess needs to return the result from theQProcesscall.in
whatEverYouWantToDo()you can iterate over the results