public class Utils extends Object
| Constructor and Description | 
|---|
| Utils() | 
| Modifier and Type | Method and Description | 
|---|---|
| static void | performAfterSync(Client client,
                TaskResponse task,
                Callback callback)Wait for a synced test and then run the given callback function. | 
| static TaskResponse | waitForSyncedTask(Client client,
                 TaskResponse task)Wait for a synced task. | 
| static TaskResponse | waitForSyncedTask(Client client,
                 TaskResponse task,
                 long timeout,
                 long sleep)Wait on a task to be synchronized. | 
public static TaskResponse waitForSyncedTask(Client client, TaskResponse task, long timeout, long sleep) throws TimeoutException
client - Client api clienttask - TaskResponse core tasktimeout - milliseconds before timing out waiting on task to syncsleep - milliseconds to sleep between checking task statusTaskResponse synced core taskTimeoutExceptionpublic static TaskResponse waitForSyncedTask(Client client, TaskResponse task) throws TimeoutException
Uses 1 second between queries to API for task status.
client - Client clienttask - TaskResponse taskTaskResponse synced core taskTimeoutExceptionpublic static void performAfterSync(Client client, TaskResponse task, Callback callback) throws Exception
client - Client clienttask - TaskResponse taskcallback - Callback callback function to run upon task syncExceptionCopyright © 2020 iland Internet Solutions, Corp. All rights reserved.