Class CustomCommand

  • All Implemented Interfaces:
    ExecutableCommand

    public class CustomCommand
    extends ExecutableCommandWrapper
    implements ExecutableCommand
    Executes an Integrity command for which there is no direct wrapper in this package.

    If an Integrity command is supported in this package (e.g. CreateItemCommand), developers are advised using it. Otherwise, for commands that are not in the scope of this library or if you have special needs, this generic command enables executing any valid Integrity command.

    Since:
    1.9.9
    • Constructor Detail

      • CustomCommand

        public CustomCommand​(com.mks.api.Command command,
                             Model model)
        Instantiates this class to execute an Integrity command.
        Parameters:
        command - the Integrity command to execute.
        model - the Model instance which was loaded with 'Application' reader
    • Method Detail

      • handleResponse

        protected void handleResponse​(com.mks.api.response.Response response)
                               throws com.mks.api.response.APIException,
                                      CoreException
        A hook to process the response received from Integrity when the command has been executed.
        Parameters:
        response - the Integrity response
        Throws:
        com.mks.api.response.APIException - if an Integrity API called on the response objects throws such exception.
        CoreException - if anything prevents from correctly processing the response.