Cocoon API: Class LinkEncodingProcessor

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

## org.apache.cocoon.processor
Class LinkEncodingProcessor

    java.lang.Object
      |
      +--org.apache.cocoon.processor.LinkEncodingProcessor

All Implemented Interfaces:
  Actor, Changeable, Processor, Status

public class LinkEncodingProcessor
extends java.lang.Object
implements Processor, Status

This class implements a LinkEncodingProcessor which encodes all URLs found in attributes specified by a Predicate. It is useful for use with cookie-less clients. You could use Xalan extension functions instead, but this is probably easier and faster, and doesn't require the use of Xalan-specific features in your stylesheet.

Version:
  $Revision: 1.7 $ $Date: 2000/12/16 15:15:31 $
Author:
  Robin Green

Constructor Summary
`LinkEncodingProcessor()`

Method Summary
`java.lang.String` | `getStatus()` Returns information about the status of the implementing class.
`boolean` | `hasChanged(java.lang.Object x)` Returns false if the requested resource hasn't changed, true otherwise.
`void` | `init(Director director)` Initialize the actor by indicating their director.
`org.w3c.dom.Document` | `process(org.w3c.dom.Document document, java.util.Dictionary parameters)` Process the DOM tree.
`protected void` | `recurse(org.w3c.dom.Element e, Predicate linkPredicate, javax.servlet.http.HttpServletResponse response)`

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

Constructor Detail

### LinkEncodingProcessor

    public LinkEncodingProcessor()

Method Detail

### init

    public void init(Director director)

  Description copied from interface: `Actor`
  Initialize the actor by indicating their director.
  Specified by:
    `init` in interface `Actor`

### process

    public org.w3c.dom.Document process(org.w3c.dom.Document document,
                                        java.util.Dictionary parameters)
                                 throws java.lang.Exception

  Description copied from interface: `Processor`
  Process the DOM tree. The returned tree is allowed to be either a copy or the modified input tree.
  Specified by:
    `process` in interface `Processor`

### recurse

    protected void recurse(org.w3c.dom.Element e,
                           Predicate linkPredicate,
                           javax.servlet.http.HttpServletResponse response)

### getStatus

    public java.lang.String getStatus()

  Description copied from interface: `Status`
  Returns information about the status of the implementing class. Note: this is use instead of the usual `toString()` method because some of these methods are declared final in some classes in JDK 1.1.
  Specified by:
    `getStatus` in interface `Status`

### hasChanged

    public boolean hasChanged(java.lang.Object x)

  Description copied from interface: `Changeable`
  Returns false if the requested resource hasn't changed, true otherwise. This method is called by the cache system to ensure the validity of the cached response. It is the producer responsibility to provide the fastest possible implementation of this method or, whether this is not possible and the costs of the change evaluation is comparable to the production costs, to return true directly with no further delay, thus reducing the evaluation overhead to a minimum. This method is guaranteed to be called after at least a single call to any production methods getStream or getDocument. The context is the trigger of the changeable point and may differ between implementations.
  Specified by:
    `hasChanged` in interface `Changeable`

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

Copyright © 1999-2001 Apache Software Foundation. All Rights Reserved.