Class IprBasedRunTypeExtension

    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void fillModel​(javax.servlet.http.HttpServletRequest request, BuildTypeForm form, java.util.Map<java.lang.String,​java.lang.Object> model)
      Called when extension should reset its' state (when GET request with init=1 parameter received).
      StatefulObject getState​(javax.servlet.http.HttpServletRequest request, BuildTypeForm form)
      Called in case if request has parameter indicating that request data should be stored in session only.
      protected void setSupportedProjectTypes​(java.util.Collection<java.lang.String> types)  
      void updateBuildType​(javax.servlet.http.HttpServletRequest request, BuildTypeForm form, BuildTypeSettings buildTypeSettings, ActionErrors errors)
      Called if validation was successful and controller is going to update build configuration.
      void updateState​(javax.servlet.http.HttpServletRequest request, BuildTypeForm form)
      Method is called on each POST request.
      ActionErrors validate​(javax.servlet.http.HttpServletRequest request, BuildTypeForm form)
      Called when user initiated save process (by clicking "Save" button).
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • MAVEN_PROJECT_TYPE

        public static final java.lang.String MAVEN_PROJECT_TYPE
        See Also:
        Constant Field Values
      • GRADLE_PROJECT_TYPE

        public static final java.lang.String GRADLE_PROJECT_TYPE
        See Also:
        Constant Field Values
      • IPR_PROJECT_TYPE

        public static final java.lang.String IPR_PROJECT_TYPE
        See Also:
        Constant Field Values
    • Constructor Detail

      • IprBasedRunTypeExtension

        protected IprBasedRunTypeExtension​(IprWebManager iprManager,
                                           SBuildServer server,
                                           java.lang.String runType)
    • Method Detail

      • setSupportedProjectTypes

        protected void setSupportedProjectTypes​(java.util.Collection<java.lang.String> types)
      • fillModel

        public void fillModel​(@NotNull
                              javax.servlet.http.HttpServletRequest request,
                              @NotNull
                              BuildTypeForm form,
                              @NotNull
                              java.util.Map<java.lang.String,​java.lang.Object> model)
        Description copied from interface: EditRunTypeControllerExtension
        Called when extension should reset its' state (when GET request with init=1 parameter received).
        Specified by:
        fillModel in interface EditRunTypeControllerExtension
        Parameters:
        request - request
        form - current form bean
        model - Spring model
      • getState

        @Nullable
        public StatefulObject getState​(@NotNull
                                       javax.servlet.http.HttpServletRequest request,
                                       @NotNull
                                       BuildTypeForm form)
        Description copied from interface: EditRunTypeControllerExtension
        Called in case if request has parameter indicating that request data should be stored in session only. Such requests are produced by JavaScript when user modified form data. In this way server tracks form state modifications.

        Extension can return implementation of StatefulObject interface encapsulating this extension state. If StatefulObject.isStateModified() method returns true then corresponding message appears in the UI.

        Specified by:
        getState in interface EditRunTypeControllerExtension
        Parameters:
        request - request
        form - current form bean
        Returns:
        this extension state
      • updateBuildType

        public void updateBuildType​(@NotNull
                                    javax.servlet.http.HttpServletRequest request,
                                    @NotNull
                                    BuildTypeForm form,
                                    @NotNull
                                    BuildTypeSettings buildTypeSettings,
                                    @NotNull
                                    ActionErrors errors)
        Description copied from interface: EditRunTypeControllerExtension
        Called if validation was successful and controller is going to update build configuration.
        Specified by:
        updateBuildType in interface EditRunTypeControllerExtension
        Parameters:
        request - request
        form - current form bean
        buildTypeSettings - build configuration settings to update
        errors - object to store errors, if an error was added then build configuration will not be persisted on disk. In this case extension is responsible for keeping build configuration consistent.
      • updateState

        public void updateState​(@NotNull
                                javax.servlet.http.HttpServletRequest request,
                                @NotNull
                                BuildTypeForm form)
        Description copied from interface: EditRunTypeControllerExtension
        Method is called on each POST request. Usually used to bind information from request to internal structure.
        Specified by:
        updateState in interface EditRunTypeControllerExtension
        Parameters:
        request - request to retrieve data from
        form - current form bean