edu.wisc.my.webproxy.beans.filtering
Class ChainingSaxFilter

java.lang.Object
  extended by org.xml.sax.helpers.XMLFilterImpl
      extended by edu.wisc.my.webproxy.beans.filtering.ChainingSaxFilter
All Implemented Interfaces:
ProxyComponent, ContentHandler, DTDHandler, EntityResolver, ErrorHandler, LexicalHandler, XMLFilter, XMLReader
Direct Known Subclasses:
BaseUrlFilter, ClippingFilter, HtmlOutputFilter

public abstract class ChainingSaxFilter
extends XMLFilterImpl
implements ProxyComponent, LexicalHandler

This abstract class can be implemented by filters that can use SAX events to perform their action.

Version:
$Id: ChainingSaxFilter.java 21818 2010-09-29 19:43:17Z edalquist $
Author:
dgrimwood

Constructor Summary
ChainingSaxFilter()
          The default constructor
ChainingSaxFilter(XMLReader parent)
          Constructor that takes XMLReader object as argument
 
Method Summary
 void characters(char[] arg0, int arg1, int arg2)
           
 void clearData()
          Called at the end of a request that the component was used in.
 void comment(char[] ch, int start, int length)
           
 void endCDATA()
           
 void endDTD()
           
 void endEntity(String name)
           
 LexicalHandler getLexicalHandler()
           
 void parse(InputSource input)
           
 void parse(String systemId)
           
 void setActionData(javax.portlet.ActionRequest request, javax.portlet.ActionResponse response)
          This method is called on a component that is being used by the portlet at the begining of the action request it will be used in.
 void setLexicalHandler(LexicalHandler lexHandler)
           
 void setParent(XMLReader parent)
           
 void setRenderData(javax.portlet.RenderRequest request, javax.portlet.RenderResponse response)
          This method is called on a component that is being used by the portlet at the begining of the render request it will be used in.
 void startCDATA()
           
 void startDTD(String name, String publicId, String systemId)
           
 void startEntity(String name)
           
 
Methods inherited from class org.xml.sax.helpers.XMLFilterImpl
endDocument, endElement, endPrefixMapping, error, fatalError, getContentHandler, getDTDHandler, getEntityResolver, getErrorHandler, getFeature, getParent, getProperty, ignorableWhitespace, notationDecl, processingInstruction, resolveEntity, setContentHandler, setDocumentLocator, setDTDHandler, setEntityResolver, setErrorHandler, setFeature, setProperty, skippedEntity, startDocument, startElement, startPrefixMapping, unparsedEntityDecl, warning
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface edu.wisc.my.webproxy.beans.config.ProxyComponent
getName
 

Constructor Detail

ChainingSaxFilter

public ChainingSaxFilter()
The default constructor


ChainingSaxFilter

public ChainingSaxFilter(XMLReader parent)
Constructor that takes XMLReader object as argument

Parameters:
parent - the (@link XMLReader) object
Method Detail

characters

public void characters(char[] arg0,
                       int arg1,
                       int arg2)
                throws SAXException
Specified by:
characters in interface ContentHandler
Overrides:
characters in class XMLFilterImpl
Throws:
SAXException
See Also:
XMLFilterImpl.characters(char[], int, int)

getLexicalHandler

public LexicalHandler getLexicalHandler()
Returns:
Returns the lexHandler.

setLexicalHandler

public void setLexicalHandler(LexicalHandler lexHandler)
Parameters:
lexHandler - The lexHandler to set.

setActionData

public void setActionData(javax.portlet.ActionRequest request,
                          javax.portlet.ActionResponse response)
Description copied from interface: ProxyComponent
This method is called on a component that is being used by the portlet at the begining of the action request it will be used in. It provides the component with a reference to the request and response objects to use.

Specified by:
setActionData in interface ProxyComponent

setRenderData

public void setRenderData(javax.portlet.RenderRequest request,
                          javax.portlet.RenderResponse response)
Description copied from interface: ProxyComponent
This method is called on a component that is being used by the portlet at the begining of the render request it will be used in. It provides the component with a reference to the request and response objects to use.

Specified by:
setRenderData in interface ProxyComponent

clearData

public void clearData()
Description copied from interface: ProxyComponent
Called at the end of a request that the component was used in. It clears the references to the request and response objects. It should be called from a finally block to ensure its execution.

Specified by:
clearData in interface ProxyComponent

setParent

public void setParent(XMLReader parent)
Specified by:
setParent in interface XMLFilter
Overrides:
setParent in class XMLFilterImpl
See Also:
XMLFilter.setParent(org.xml.sax.XMLReader)

parse

public void parse(InputSource input)
           throws SAXException,
                  IOException
Specified by:
parse in interface XMLReader
Overrides:
parse in class XMLFilterImpl
Throws:
SAXException
IOException
See Also:
XMLReader.parse(org.xml.sax.InputSource)

parse

public void parse(String systemId)
           throws SAXException,
                  IOException
Specified by:
parse in interface XMLReader
Overrides:
parse in class XMLFilterImpl
Throws:
SAXException
IOException
See Also:
XMLReader.parse(java.lang.String)

comment

public void comment(char[] ch,
                    int start,
                    int length)
             throws SAXException
Specified by:
comment in interface LexicalHandler
Throws:
SAXException
See Also:
LexicalHandler.comment(char[], int, int)

endCDATA

public void endCDATA()
              throws SAXException
Specified by:
endCDATA in interface LexicalHandler
Throws:
SAXException
See Also:
LexicalHandler.endCDATA()

endDTD

public void endDTD()
            throws SAXException
Specified by:
endDTD in interface LexicalHandler
Throws:
SAXException
See Also:
LexicalHandler.endDTD()

startCDATA

public void startCDATA()
                throws SAXException
Specified by:
startCDATA in interface LexicalHandler
Throws:
SAXException
See Also:
LexicalHandler.startCDATA()

endEntity

public void endEntity(String name)
               throws SAXException
Specified by:
endEntity in interface LexicalHandler
Throws:
SAXException
See Also:
LexicalHandler.endEntity(java.lang.String)

startEntity

public void startEntity(String name)
                 throws SAXException
Specified by:
startEntity in interface LexicalHandler
Throws:
SAXException
See Also:
LexicalHandler.startEntity(java.lang.String)

startDTD

public void startDTD(String name,
                     String publicId,
                     String systemId)
              throws SAXException
Specified by:
startDTD in interface LexicalHandler
Throws:
SAXException
See Also:
LexicalHandler.startDTD(java.lang.String, java.lang.String, java.lang.String)


Copyright © 2010 Jasig. All Rights Reserved.