Uploaded image for project: 'Wicket'
  1. Wicket
  2. WICKET-220

Form's handleMultiPart() method needs to be overridable to allow custom processing of multi-part streams

VotersWatch issueWatchersLinkCloneUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

Details

    • New Feature
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 2.0 branch (discontinued), 1.2.4, 1.2.5, 1.3.0-beta1
    • wicket
    • None

    Description

      Currently handleMultiPart() method is declared "private final" in wicket.markup.html.form.Form class, and implementation of the uploaded parts of the multi-part stream on the server side.is tied to the File-type in the code, especially the code related to the FileUploadField class. Making handleMultiPart() "protected" instead of "private final" will allow custom "per form" multi-part HTTP POST stream processing. In particular, the processing will become possible, which is not tied to a particular implementation of the uploaded parts of the multi-part stream on the server side. It shall be noted in the Javadoc that overriding handleMultiPart() method will likely break FileUploadField logic. Also, it may be worth extracting the non-File-specific portion of the FileUploadField class logic into the base class (e.g., StreamUploadField), and advise using that base class instead of FileUploadField for non-File-specific uploads.

      Attachments

        1. FileUploadField.java
          3 kB
          Bob Brokman
        2. StreamUploadField.java
          3 kB
          Bob Brokman

        Activity

          This comment will be Viewable by All Users Viewable by All Users
          Cancel

          People

            ivaynberg Igor Vaynberg
            beboris Bob Brokman
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Slack

                Issue deployment