org.xwiki.portlet.view
Class CSSStreamFilter

java.lang.Object
  extended by org.xwiki.portlet.view.CSSStreamFilter
All Implemented Interfaces:
StreamFilter

public class CSSStreamFilter
extends Object
implements StreamFilter

Rewrites a CSS stream so that it can be used by a portlet in a portal page without affecting other portlets or the portal page itself. The following transformations are executed:

.

Version:
$Id: 9313f650c7e8a006c03603130b5bcd9eb833f4ad $

Constructor Summary
CSSStreamFilter(String namespace, URLRewriter urlRewriter)
          Creates a new CSS stream filter that uses the given URL rewriter to transform import URLs and the given name-space to prevent style rules from affecting other portlets or the portal page itself.
 
Method Summary
 void filter(Reader reader, Writer writer)
          Filters the given character stream.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CSSStreamFilter

public CSSStreamFilter(String namespace,
                       URLRewriter urlRewriter)
Creates a new CSS stream filter that uses the given URL rewriter to transform import URLs and the given name-space to prevent style rules from affecting other portlets or the portal page itself.

Parameters:
namespace - the portlet name-space
urlRewriter - the object used to rewrite servlet URLs
Method Detail

filter

public void filter(Reader reader,
                   Writer writer)
Description copied from interface: StreamFilter
Filters the given character stream.

Specified by:
filter in interface StreamFilter
Parameters:
reader - the character stream to be filtered
writer - the resulting character stream


Copyright © 2004-2013 XWiki. All Rights Reserved.