public static void tasks(GEnRouteManager manager) { GTaskManager taskManager = manager.getTaskManager(); // Enumerate tasks foreach (GTask taskFromList in taskManager.getTasks()) { // Do something with each task } // Start top pending task. Notes // - task list may be empty GTask task = taskManager.getPendingTasks().at(0); taskManager.startTask(task); // Change task phase to "live". Notes // - task needs to be in active state // - operation object needs to be available taskManager.setOperationPhase(task.getOperation(), EnRouteConstants.PHASE_PROPERTY_LIVE()); // Complete task. Notes // - task needs to be in active state // - operation object needs to be available taskManager.completeOperation(task.getOperation()); }
public static void onAppStart(GEnRouteManager manager) { if (manager.isLoginNeeded()) { manager.login(_driverEmail, _driverPassword); } else { manager.start(); } }
public App(GEnRouteFactory enRouteFactory) { _enRouteFactory = enRouteFactory; _enRouteManager = _enRouteFactory.createEnRouteManager(); // The root page of your application MainPage = new ContentPage { Content = new StackLayout { VerticalOptions = LayoutOptions.Center, Children = { new Label { XAlign = TextAlignment.Center, Text = "Welcome to Xamarin Forms!" } } } }; }
public static void onDriverLogout(GEnRouteManager manager) { manager.logout(EnRouteConstants.LOGOUT_REASON_USER_ACTION); }
public Controller(GEnRouteManager manager) { _manager = manager; }
public void unsubscribe(GEnRouteManager manager) { manager.removeListener(this); }
public void subscribe(GEnRouteManager manager) { manager.addListener(this); }