Class SupersetDashboard.FetchGuestTokenTask

java.lang.Object
io.jmix.flowui.backgroundtask.BackgroundTask<Void,GuestTokenResponse>
io.jmix.supersetflowui.component.SupersetDashboard.FetchGuestTokenTask
Enclosing class:
SupersetDashboard

protected class SupersetDashboard.FetchGuestTokenTask extends BackgroundTask<Void,GuestTokenResponse>
  • Field Details

  • Constructor Details

    • FetchGuestTokenTask

      public FetchGuestTokenTask(long timeout, GuestTokenBody body, String accessToken, @Nullable String csrfToken)
  • Method Details

    • run

      Description copied from class: BackgroundTask
      Main method that performs a task.
      Called by the execution environment in a separate working thread.
      Implementation of this method should support interruption:
      Specified by:
      run in class BackgroundTask<Void,GuestTokenResponse>
      Parameters:
      taskLifeCycle - lifecycle object that allows the main method to interact with the execution environment
      Returns:
      task result
      Throws:
      IOException
      InterruptedException
    • done

      public void done(GuestTokenResponse response)
      Description copied from class: BackgroundTask
      Provides exclusive access to this UI from outside a request handling thread when the task is completed.

      Please note that the command might be invoked on a different thread or later on the current thread, which means that custom thread locals might not have the expected values when the command is executed. UI.getCurrent(), VaadinSession.getCurrent() and VaadinService.getCurrent() are set according to this UI before executing the command. Other standard CurrentInstance values such as VaadinService.getCurrentRequest() and VaadinService.getCurrentResponse() will not be defined.

      Overrides:
      done in class BackgroundTask<Void,GuestTokenResponse>
      Parameters:
      response - result of execution returned by BackgroundTask.run(TaskLifeCycle) method
      See Also:
      • UI.access(Command)
    • isAccessTokenExpired

      protected boolean isAccessTokenExpired(@Nullable String message)