MyFaces Tobago
  1. MyFaces Tobago
  2. TOBAGO-390 Posibillity for Tobago components to use other ResponseWriter
  3. TOBAGO-393

Create OptimizedResponseWriter to move the non-standard-compliant optimization stuff to

    Details

    • Type: Sub-task Sub-task
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 1.0.11
    • Component/s: Core
    • Labels:
      None

      Description

      This is needed to make optimizations possible.
      e.g. the id-,name-, class-attribute values are not needed to be HTML escaped. But the interface ResponseWriter doesn't allow to write without closing the startElement-tag.

      The Tobago renderers may call

      OptimizedResponseWriter writer = HtmlRendererUtil.getOptimizedResponseWriter(facesContext);

      to get a writer. The static method getOptimizedResponseWriter() may return the TobagoResponseWriter which implements the OptimizedResponseWriter or otherwize return a wrapped object of the given ResponseWriter.

      The new OptimizedResponseWriterWrapper class is not optimized, because of the closing-of-the-startElement restriction.

      Remove automatical check of needed escaping from TobagoResponseWriter. Special id-, name-, class-attribute setter should be called.

        Activity

        Hide
        Bernd Bohmann added a comment -

        I think the interface OptimizedResponseWriter should called TobagoResponseWriter because this interface define the extra tobago write methods.
        The TobagoResponseWriter should called OptimizedTobagoResponseWriter and the Wrapper for the none TobagoResponseWriterImp maybe
        TobagoResponseWriterWrapper or something else.

        Show
        Bernd Bohmann added a comment - I think the interface OptimizedResponseWriter should called TobagoResponseWriter because this interface define the extra tobago write methods. The TobagoResponseWriter should called OptimizedTobagoResponseWriter and the Wrapper for the none TobagoResponseWriterImp maybe TobagoResponseWriterWrapper or something else.
        Hide
        Udo Schnurpfeil added a comment -

        Okay, thats a good point. But I would prefer:

        TobagoResponseWriter for the interface,
        TobagoResponseWriterImpl for the default Tobago implementation and
        TobagoResponseWriterWrapper for the implementation, which wrappes other standard writers

        Show
        Udo Schnurpfeil added a comment - Okay, thats a good point. But I would prefer: TobagoResponseWriter for the interface, TobagoResponseWriterImpl for the default Tobago implementation and TobagoResponseWriterWrapper for the implementation, which wrappes other standard writers
        Hide
        Bernd Bohmann added a comment -

        Ok

        Show
        Bernd Bohmann added a comment - Ok

          People

          • Assignee:
            Udo Schnurpfeil
            Reporter:
            Udo Schnurpfeil
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development