Hello!
What is the logic of using WaitChange and GetNextTask requests?
As an example - we need to know the result of added task. Should we poll the server asking the result?
What is the best way of polling?
You need to poll the server to ask for the new task. You do it calling WaitChange. You define how long you want to wait for a new task using WaitTime property. You can also define what kind of tasks you are interested in using the Change property of WaitChange. WaitChange can be used to build UI. Server notifies when new meters are added, etc. The function returns when there is a new task or timeout occurs.
When there are a new task, you can use GetNextTask to get the actual task. WaitChange only reports that a new task is added, but it doesn't return the task.
Hi,
Hi,
You need to poll the server to ask for the new task. You do it calling WaitChange. You define how long you want to wait for a new task using WaitTime property. You can also define what kind of tasks you are interested in using the Change property of WaitChange. WaitChange can be used to build UI. Server notifies when new meters are added, etc. The function returns when there is a new task or timeout occurs.
When there are a new task, you can use GetNextTask to get the actual task. WaitChange only reports that a new task is added, but it doesn't return the task.
BR,
Mikko