org.springframework.web.servlet.tags.form

Class AbstractCheckedElementTag

    • Constructor Detail

      • AbstractCheckedElementTag

        public AbstractCheckedElementTag()
    • Method Detail

      • renderFromValue

        protected void renderFromValue(@Nullable
                                       java.lang.Object value,
                                       TagWriter tagWriter)
                                throws JspException
        Render the 'input(checkbox)' with the supplied value, marking the 'input' element as 'checked' if the supplied value matches the bound value.
        Throws:
        JspException
      • renderFromValue

        protected void renderFromValue(@Nullable
                                       java.lang.Object item,
                                       @Nullable
                                       java.lang.Object value,
                                       TagWriter tagWriter)
                                throws JspException
        Render the 'input(checkbox)' with the supplied value, marking the 'input' element as 'checked' if the supplied value matches the bound value.
        Throws:
        JspException
      • renderFromBoolean

        protected void renderFromBoolean(java.lang.Boolean boundValue,
                                         TagWriter tagWriter)
                                  throws JspException
        Render the 'input(checkbox)' with the supplied value, marking the 'input' element as 'checked' if the supplied Boolean is true.
        Throws:
        JspException
      • isValidDynamicAttribute

        protected boolean isValidDynamicAttribute(java.lang.String localName,
                                                  java.lang.Object value)
        Flags "type" as an illegal dynamic attribute.
        Overrides:
        isValidDynamicAttribute in class AbstractHtmlElementTag
      • getInputType

        protected abstract java.lang.String getInputType()
        Return the type of the HTML input element to generate: "checkbox" or "radio".