Tapestry
  1. Tapestry
  2. TAPESTRY-220

InsertText should accept java.io.Reader in addition to String

    Details

    • Type: New Feature New Feature
    • Status: Open
    • Priority: Major Major
    • Resolution: Unresolved
    • Affects Version/s: 3.0.1
    • Fix Version/s: 4.2
    • Component/s: Framework
    • Labels:
      None

      Description

      In order to display a relatively big text file from a database its entire content has to be stored in a String before it can be passed to the InsertText component. This is a waste of time and memory.

      To solve this problem the InsertText component should accept a java.io.Reader in addition to a String. Then all the user has to do is create an InputStreamReader and pass it to the component directly.

      I have applied a patch for Tapestry 3.0.1. It changes to type of the parameter value from String to Object and performs a runtime test to see if it is a String or a Reader. Of course an additional parameter could be used if this is not desired.

      1. inserttext.patch
        3 kB
        Markus Wiederkehr

        Activity

        Mark Thomas made changes -
        Workflow Default workflow, editable Closed status [ 12568018 ] jira [ 12591126 ]
        Mark Thomas made changes -
        Workflow jira [ 38122 ] Default workflow, editable Closed status [ 12568018 ]
        Jesse Kuhnert made changes -
        Fix Version/s 4.1.2 [ 12312202 ]
        Fix Version/s 4.2 [ 12312203 ]
        Jesse Kuhnert made changes -
        Fix Version/s 4.1.2 [ 12312202 ]
        Markus Wiederkehr made changes -
        Field Original Value New Value
        Attachment inserttext.patch [ 18065 ]
        Markus Wiederkehr created issue -

          People

          • Assignee:
            Unassigned
            Reporter:
            Markus Wiederkehr
          • Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:

              Development