Interface IDominoAction

  • All Known Implementing Classes:
    UserAccess, UserDeletion, UserRegistration

    public interface IDominoAction
    IDominoAction provides a common interface for classes that perfom a special Action with Domino.

    Such classes will capsulate the necessary data to perform the operation and perform the operation itself. They will act as static mechanisms used by the DominoUsersConnector to perform special actions. Common pattern for all IDominoAction-s is that they will take the decision if the Action has to be performed and get the neccesary data to perform the Action based on a fixed schema of Entry Attributes.

    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      java.lang.String canPerform()
      Inspects the data stored in the local data holders and determines if it is consistent and the Domino Action can be performed.
      Entry extractAndStoreData​(Entry aEntry)
      This method extracts and stores data.
      boolean mustPerform​(Entry aEntry)
      Inspects the Attributes of the given Entry and determines if the Domino Action has to be performed.
      void perform()
      Performs the Domino Action useing the data from the local data holders.
      void resetData()
      Resets the local data holders to empty/default values according the business logic of the Domino Action.
    • Method Detail

      • extractAndStoreData

        Entry extractAndStoreData​(Entry aEntry)
                           throws java.lang.Exception
        This method extracts and stores data. It performs the following actions:

        (1) Extract data from the given Entry according to the fixed schema of Attributes;

        (2) Stores this data into local data holders;

        Parameters:
        aEntry - The Entry object to extract data from.
        Returns:
        an Entry object that contains all Attributes of the aEntry parameter except those from the fixed schema.
        Throws:
        java.lang.Exception - if an error that cannot be handled occurs while operating.
      • mustPerform

        boolean mustPerform​(Entry aEntry)
                     throws java.lang.Exception
        Inspects the Attributes of the given Entry and determines if the Domino Action has to be performed.
        Parameters:
        aEntry - The Entry object which Attributes hold the necessary information whether to perform the Domino Action.
        Returns:
        "true" if the Domino Action must be performed; "false" otherwise.
        Throws:
        java.lang.Exception - if an error that cannot be handled occurs while operating.
      • canPerform

        java.lang.String canPerform()
        Inspects the data stored in the local data holders and determines if it is consistent and the Domino Action can be performed.
        Returns:
        "null" if the Domino Action can be performed with the current data;

        and a non-empty string message explaining the problem, if the data is not consistent and the Action cannot be performed.

      • perform

        void perform()
              throws java.lang.Exception
        Performs the Domino Action useing the data from the local data holders.
        Throws:
        java.lang.Exception - if an error that cannot be handled occurs while operating.
      • resetData

        void resetData()
                throws java.lang.Exception
        Resets the local data holders to empty/default values according the business logic of the Domino Action.
        Throws:
        java.lang.Exception - if an error that cannot be handled occurs while operating.