Class FirstLoginWizardPage

java.lang.Object
org.eclipse.jface.dialogs.DialogPage
org.eclipse.jface.wizard.WizardPage
com.developer.nefarious.zjoule.plugin.login.pages.FirstLoginWizardPage
All Implemented Interfaces:
org.eclipse.jface.dialogs.IDialogPage, org.eclipse.jface.dialogs.IMessageProvider, org.eclipse.jface.wizard.IWizardPage

public class FirstLoginWizardPage extends org.eclipse.jface.wizard.WizardPage
Represents the first page of the login wizard where the user provides SAP AI Core credentials.

This page includes:

  • A text field for entering the content of the service key JSON.
  • An error message widget for validation feedback.
  • Logic to propagate resource group information to subsequent wizard pages.
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final String
    The unique identifier for this wizard page.

    Fields inherited from interface org.eclipse.jface.dialogs.IMessageProvider

    ERROR, INFORMATION, NONE, WARNING
  • Constructor Summary

    Constructors
    Constructor
    Description
    Constructs a new FirstLoginWizardPage.
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    createControl(org.eclipse.swt.widgets.Composite parent)
    Creates the UI controls for this wizard page.
    Retrieves the text entered by the user in the input field.
    Retrieves the ServiceKey parsed from the user input.
    void
    Propagates resource groups from the service key response to the second wizard page.
    void
    Sets the ServiceKey for this page.
    void
    Displays a validation error message in the UI or hides it if the message is null or empty.

    Methods inherited from class org.eclipse.jface.wizard.WizardPage

    canFlipToNextPage, getContainer, getDialogSettings, getImage, getName, getNextPage, getPreviousPage, getShell, getWizard, isCurrentPage, isPageComplete, setDescription, setErrorMessage, setImageDescriptor, setMessage, setPageComplete, setPreviousPage, setTitle, setWizard, toString

    Methods inherited from class org.eclipse.jface.dialogs.DialogPage

    convertHeightInCharsToPixels, convertHorizontalDLUsToPixels, convertVerticalDLUsToPixels, convertWidthInCharsToPixels, dispose, getControl, getDescription, getDialogFontName, getErrorMessage, getFont, getMessage, getMessageType, getTitle, getToolTipText, initializeDialogUnits, isControlCreated, performHelp, setButtonLayoutData, setControl, setMessage, setVisible

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait

    Methods inherited from interface org.eclipse.jface.dialogs.IDialogPage

    dispose, getControl, getDescription, getErrorMessage, getMessage, getTitle, performHelp, setVisible

    Methods inherited from interface org.eclipse.jface.wizard.IWizardPage

    getMinimumPageSize
  • Field Details

  • Constructor Details

    • FirstLoginWizardPage

      public FirstLoginWizardPage(ILoginClient loginClient)
      Constructs a new FirstLoginWizardPage.
      Parameters:
      loginClient - the ILoginClient used for API interactions during the login process.
  • Method Details

    • createControl

      public void createControl(org.eclipse.swt.widgets.Composite parent)
      Creates the UI controls for this wizard page.
      Parameters:
      parent - the parent Composite for the wizard page controls.
    • getInputText

      public String getInputText()
      Retrieves the text entered by the user in the input field.
      Returns:
      the user input as a String.
    • getServiceKey

      public ServiceKey getServiceKey()
      Retrieves the ServiceKey parsed from the user input.
      Returns:
      the ServiceKey object.
    • setResourceGroupsOnTheSecondPage

      public void setResourceGroupsOnTheSecondPage(GetResourceGroupsResponse getResourceGroupsResponse)
      Propagates resource groups from the service key response to the second wizard page.
      Parameters:
      getResourceGroupsResponse - the response containing available resource groups.
    • setServiceKey

      public void setServiceKey(ServiceKey serviceKey)
      Sets the ServiceKey for this page.
      Parameters:
      serviceKey - the ServiceKey object to set.
    • setValidationError

      public void setValidationError(String message)
      Displays a validation error message in the UI or hides it if the message is null or empty.

      If an error message is displayed, the page is marked as incomplete. Otherwise, it is marked as complete.

      Parameters:
      message - the error message to display, or null to hide the error widget.