Class STSInstanceModelBase

    • Method Detail

      • createInstance

        public STSInstanceModelResponse createInstance​(STSHomeViewBeanModel.STSType stsType,
                                                       Map<String,​Set<String>> configurationState,
                                                       String realm)
                                                throws AMConsoleException
        Description copied from interface: STSInstanceModel
        Publishes a rest sts instance by POSTing to the rest-sts publish endpoint.
        Specified by:
        createInstance in interface STSInstanceModel
        Parameters:
        stsType - is the request for soap or rest instances
        configurationState - the configuration state defining the published instance
        realm - the realm in which the instance should be published. Necessary to add the realm state to the configuration state, as the end-user should not be able to set this directly (i.e. it is implicit in the ViewBean display)
        Returns:
        A RestSTSModelResonse instance, which encapsulates success or failure, and a optional success/failure message
        Throws:
        AMConsoleException - If an IOException occurs in making the POST
      • updateInstance

        public STSInstanceModelResponse updateInstance​(STSHomeViewBeanModel.STSType stsType,
                                                       Map<String,​Set<String>> configurationState,
                                                       String realm,
                                                       String instanceName)
                                                throws AMConsoleException
        Description copied from interface: STSInstanceModel
        Updates a rest sts instance by PUTing to the rest-sts publish endpoint.
        Specified by:
        updateInstance in interface STSInstanceModel
        Parameters:
        stsType - is the request for soap or rest instances
        configurationState - the configuration state defining the updated instance
        realm - the realm in which the instance should be published. Necessary to add the realm state to the configuration state, as the end-user should not be able to set this directly (i.e. it is implicit in the ViewBean display)
        instanceName - The name of the instance, as set by the ViewBean. Used to constitute the PUT url.
        Returns:
        A RestSTSModelResonse instance, which encapsulates success or failure, and optional success/failure messages
        Throws:
        AMConsoleException - If an IOException occurs in making the PUT
      • getInstanceState

        public Map<String,​Set<String>> getInstanceState​(STSHomeViewBeanModel.STSType stsType,
                                                              String realm,
                                                              String instanceName)
                                                       throws AMConsoleException
        Description copied from interface: STSInstanceModel
        Called by the RestSTSEditViewBean to obtain the instance state necessary to edit an existing rest sts instance.
        Specified by:
        getInstanceState in interface STSInstanceModel
        Parameters:
        stsType - is the request for soap or rest instances
        realm - the realm to which the instance has been published
        instanceName - the instance name
        Returns:
        The state corresponding to the rest sts instance which is used to constitute the property-sheet displayed by the RestSTSEditViewBean
        Throws:
        AMConsoleException - If the SMS cannot be consulted.
      • validateConfigurationState

        public STSInstanceModelResponse validateConfigurationState​(STSHomeViewBeanModel.STSType stsType,
                                                                   Map<String,​Set<String>> configurationState)
        Description copied from interface: STSInstanceModel
        Called by the ViewBean context prior to updating or publishing a rest sts instance.
        Specified by:
        validateConfigurationState in interface STSInstanceModel
        Parameters:
        stsType - is the request for soap or rest instances
        configurationState - the to-be-validated configuration state
        Returns:
        A STSInstanceModelResponse indicating validation success or failure. If validation was not successful, the message will indicate the validation error.