Class ServiceDialog

java.lang.Object
org.purl.sword.client.ServiceDialog

public class ServiceDialog extends Object
Dialog that prompts the user to enter the details for a service document location.
Author:
Neil Taylor
  • Constructor Details

    • ServiceDialog

      public ServiceDialog(JFrame parentFrame)
      Create a new instance.
      Parameters:
      parentFrame - The parent frame. The dialog will be shown over the centre of this frame.
  • Method Details

    • show

      public int show()
      Show the dialog.
      Returns:
      The close option. This is one of the dialog options from JOptionPane.
    • createControls

      protected final JPanel createControls()
      Create the controls that are displayed in the dialog.
      Returns:
      The panel that contains the controls.
    • getUsername

      public String getUsername()
      Get the username from the controls on the dialog.
      Returns:
      The username.
    • getPassword

      public String getPassword()
      Get the password from the dialog.
      Returns:
      The password.
    • getLocation

      public String getLocation()
      The location from the dialog.
      Returns:
      The location.
    • getOnBehalfOf

      public String getOnBehalfOf()
      The onBehalfOf value from the dialog.
      Returns:
      The onBehalfOf value.
    • addUserIds

      public void addUserIds(String[] users)
      Add the list of user ids to the dialog.
      Parameters:
      users - The list of user ids.
    • addServiceUrls

      public void addServiceUrls(String[] services)
      Add the list of service URLs.
      Parameters:
      services - The service URLs.
    • addOnBehalfOf

      public void addOnBehalfOf(String[] users)
      Add a list of onBehalfOf names.
      Parameters:
      users - The list of onBehalfOf items.