Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.jasig.portal.channels.webproxy
Class CWebProxyXHTMLURLFilter

    java.lang.Object
      org.jasig.portal.utils.SAX2FilterImpl
          org.jasig.portal.channels.webproxy.CWebProxyURLFilter
              org.jasig.portal.channels.webproxy.CWebProxyXHTMLURLFilter

All Implemented Interfaces:
  org.xml.sax.ContentHandler, org.xml.sax.DTDHandler, org.xml.sax.EntityResolver, org.xml.sax.ErrorHandler, org.xml.sax.ext.LexicalHandler, org.xml.sax.XMLFilter, org.xml.sax.XMLReader

    public class CWebProxyXHTMLURLFilter

extends CWebProxyURLFilter

Rewrites URLs for CWebProxy in an XHTML document.

Version:
  $Revision: 1.10 $
Author:
  Sarah Arnott, sarnott@mun.ca

Nested Class Summary
`private class` | `CWebProxyXHTMLURLFilter.FormFilter` A helper class which rewrites the action attribute in a form element.

Field Summary
`private java.lang.String` | `actionURL`
`private SAX2BufferImpl` | `buffer`
`private boolean` | `insideForm`
`private static org.apache.commons.logging.Log` | `log`
`private boolean` | `markedInputExists`
`private java.lang.String` | `newActionValue`
`private java.lang.String` | `origActionValue`
`private java.lang.String` | `passThrough`

Fields inherited from class org.jasig.portal.channels.webproxy.CWebProxyURLFilter
`baseUrl, runtimeData`

Fields inherited from class org.jasig.portal.utils.SAX2FilterImpl
`contentHandler, dtdHandler, entityResolver, errorHandler, lexicalHandler, locator`

Constructor Summary
`CWebProxyXHTMLURLFilter(org.xml.sax.ContentHandler handler)` A constructor which receives a ContentHandler to which filtered SAX events are passed.

Method Summary
`private void` | `addInputToBuffer()` Adds an input element to the form to pass original action attribute value to CWebProxy.
`void` | `characters(char[] ch, int start, int length)` Filter a character data event.
`void` | `endElement(java.lang.String uri, java.lang.String localName, java.lang.String qName)` Filter an end element event.
`private void` | `initRewrite()` Sets newActionValue for FormFilter to modify and adds an input element to buffer, if required.
`void` | `startElement(java.lang.String uri, java.lang.String localName, java.lang.String qName, org.xml.sax.Attributes atts)` Filter a start element event.

Methods inherited from class org.jasig.portal.channels.webproxy.CWebProxyURLFilter
`getBase, getQueryString, newCWebProxyURLFilter, rewriteURL`

Methods inherited from class org.jasig.portal.utils.SAX2FilterImpl
`comment, endCDATA, endDocument, endDTD, endEntity, endPrefixMapping, error, fatalError, getContentHandler, getDTDHandler, getEntityResolver, getErrorHandler, getFeature, getParent, getProperty, ignorableWhitespace, notationDecl, parse, parse, processingInstruction, resolveEntity, setAllHandlers, setContentHandler, setDocumentLocator, setDTDHandler, setEntityResolver, setErrorHandler, setFeature, setLexicalHandler, setParent, setProperty, skippedEntity, startCDATA, startDocument, startDTD, startEntity, startPrefixMapping, unparsedEntityDecl, warning`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### log

    private static final org.apache.commons.logging.Log log

### buffer

    private SAX2BufferImpl buffer

### insideForm

    private boolean insideForm

### markedInputExists

    private boolean markedInputExists

### actionURL

    private java.lang.String actionURL

### origActionValue

    private java.lang.String origActionValue

### newActionValue

    private java.lang.String newActionValue

### passThrough

    private java.lang.String passThrough

Constructor Detail

### CWebProxyXHTMLURLFilter

    public CWebProxyXHTMLURLFilter(org.xml.sax.ContentHandler handler)

  A constructor which receives a ContentHandler to which filtered SAX events are passed.

  Parameters:
    `handler` - the ContentHandler to which filtered SAX events are passed

Method Detail

### startElement

    public void startElement(java.lang.String uri,
                             java.lang.String localName,
                             java.lang.String qName,
                             org.xml.sax.Attributes atts)
                      throws org.xml.sax.SAXException

  Description copied from class: `SAX2FilterImpl`
  Filter a start element event.

  Specified by:
    `startElement` in interface `org.xml.sax.ContentHandler`
  Overrides:
    `startElement` in class `SAX2FilterImpl`
  Parameters:
    `uri` - The element's Namespace URI, or the empty string.
    `localName` - The element's local name, or the empty string.
    `qName` - The element's qualified (prefixed) name, or the empty string.
    `atts` - The element's attributes.
  Throws:
    `org.xml.sax.SAXException` - The client may throw an exception during processing.
  See Also:
    `ContentHandler.startElement(java.lang.String, java.lang.String, java.lang.String, org.xml.sax.Attributes)`

### endElement

    public void endElement(java.lang.String uri,
                           java.lang.String localName,
                           java.lang.String qName)
                    throws org.xml.sax.SAXException

  Description copied from class: `SAX2FilterImpl`
  Filter an end element event.

  Specified by:
    `endElement` in interface `org.xml.sax.ContentHandler`
  Overrides:
    `endElement` in class `SAX2FilterImpl`
  Parameters:
    `uri` - The element's Namespace URI, or the empty string.
    `localName` - The element's local name, or the empty string.
    `qName` - The element's qualified (prefixed) name, or the empty string.
  Throws:
    `org.xml.sax.SAXException` - The client may throw an exception during processing.
  See Also:
    `ContentHandler.endElement(java.lang.String, java.lang.String, java.lang.String)`

### characters

    public void characters(char[] ch,
                           int start,
                           int length)
                    throws org.xml.sax.SAXException

  Description copied from class: `SAX2FilterImpl`
  Filter a character data event.

  Specified by:
    `characters` in interface `org.xml.sax.ContentHandler`
  Overrides:
    `characters` in class `SAX2FilterImpl`
  Parameters:
    `ch` - An array of characters.
    `start` - The starting position in the array.
    `length` - The number of characters to use from the array.
  Throws:
    `org.xml.sax.SAXException` - The client may throw an exception during processing.
  See Also:
    `ContentHandler.characters(char[], int, int)`

### initRewrite

    private void initRewrite()

  Sets newActionValue for FormFilter to modify and adds an input element to buffer, if required.

### addInputToBuffer

    private void addInputToBuffer()

  Adds an input element to the form to pass original action attribute value to CWebProxy.

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD