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

## com.jclark.xsl.sax
Class ResultBase

    java.lang.Object
      com.jclark.xsl.sax.ResultBase

All Implemented Interfaces:
  org.xml.sax.AttributeList, Result

Direct Known Subclasses:
  MultiNamespaceResult

public abstract class ResultBase
extends java.lang.Object
implements Result, org.xml.sax.AttributeList

abstract base class represents the results of executing a stylesheet Action -- constructs result components. events are fired to the Result, which in turn fires events to a SAX (1) DocumentHandler

Method Summary
`void` | `attribute(Name name, java.lang.String value)` construct an Attribute with the given name ... if we're not at an appropriate point, eg, we've already started putting text into an element, do nothing
`void` | `characters(java.lang.String str)` construct some characters in the result
`void` | `comment(java.lang.String str)` construct a comment in our result
`void` | `end()` flush any pending construction work, nothing else will be built
`void` | `endElement(Name elementType)` Finish constructing an Element
`protected abstract void` | `endElementContent(Name elementType)`
`void` | `flush()` call this when we're sure we're not getting any more attribute node constructing actions
`protected Name` | `getAttributeName(int i)`
`protected org.xml.sax.DocumentHandler` | `getDocumentHandler()`
`int` | `getLength()`
`java.lang.String` | `getType(int i)`
`java.lang.String` | `getType(java.lang.String name)`
`java.lang.String` | `getValue(int i)`
`java.lang.String` | `getValue(java.lang.String name)`
`void` | `message(Node node, java.lang.String str)` Support the `xsl:message` element.
`void` | `processingInstruction(java.lang.String target, java.lang.String data)` construct a processingInstruction in the result
`void` | `rawCharacters(java.lang.String str)` rawCharacters are distinct from plain 'ol characters in that we don't try to do any escaping
`abstract void` | `resultTreeFragment(ResultTreeFragment frag)`
`void` | `start(OutputMethod outputMethod)` initialize, (and possibly construct) the DocumentHandler
`void` | `startElement(Name elementType, NamespacePrefixMap nsMap)` start construction an Element
`protected abstract void` | `startElementContent(Name elementType, NamespacePrefixMap nsMap)` we're finished with adding attributes?
`protected void` | `throwXSLException(org.xml.sax.SAXException e)`

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

Methods inherited from interface com.jclark.xsl.tr.Result
`createResult`

Methods inherited from interface org.xml.sax.AttributeList
`getName`

Method Detail

### flush

    public void flush()
               throws XSLException

  call this when we're sure we're not getting any more attribute node constructing actions

  Throws:
    `XSLException`

### rawCharacters

    public void rawCharacters(java.lang.String str)
                       throws XSLException

  rawCharacters are distinct from plain 'ol characters in that we don't try to do any escaping

  Specified by:
    `rawCharacters` in interface `Result`
  Throws:
    `XSLException`

### characters

    public void characters(java.lang.String str)
                    throws XSLException

  construct some characters in the result

  Specified by:
    `characters` in interface `Result`
  Throws:
    `XSLException`

### comment

    public void comment(java.lang.String str)
                 throws XSLException

  construct a comment in our result

  Specified by:
    `comment` in interface `Result`
  Throws:
    `XSLException`

### processingInstruction

    public void processingInstruction(java.lang.String target,
                                      java.lang.String data)
                               throws XSLException

  construct a processingInstruction in the result

  Specified by:
    `processingInstruction` in interface `Result`
  Throws:
    `XSLException`

### startElement

    public void startElement(Name elementType,
                             NamespacePrefixMap nsMap)
                      throws XSLException

  start construction an Element

  Specified by:
    `startElement` in interface `Result`
  Throws:
    `XSLException`

### endElement

    public void endElement(Name elementType)
                    throws XSLException

  Description copied from interface: `Result`
  Finish constructing an Element

  Specified by:
    `endElement` in interface `Result`
  Throws:
    `XSLException`

### getDocumentHandler

    protected final org.xml.sax.DocumentHandler getDocumentHandler()

### getLength

    public int getLength()

  Specified by:
    `getLength` in interface `org.xml.sax.AttributeList`
  Returns:
    the number of attribute nodes we have at this moment

### getAttributeName

    protected final Name getAttributeName(int i)

  Returns:
    the name of the i'th Attribute

### getValue

    public java.lang.String getValue(int i)

  Specified by:
    `getValue` in interface `org.xml.sax.AttributeList`
  Returns:
    the value of the i'th Attribute

### getType

    public java.lang.String getType(int i)

  Specified by:
    `getType` in interface `org.xml.sax.AttributeList`
  Returns:
    the type of the i'th Attribute (always "CDATA")

### getType

    public java.lang.String getType(java.lang.String name)

  Specified by:
    `getType` in interface `org.xml.sax.AttributeList`
  Returns:
    the type of the named Attribute (always "CDATA")

### getValue

    public java.lang.String getValue(java.lang.String name)

  Specified by:
    `getValue` in interface `org.xml.sax.AttributeList`
  Returns:
    the value of the named Attribute (always "CDATA") .. not sure how these names work with namespaces returns null if the named Attribute is not found

### startElementContent

    protected abstract void startElementContent(Name elementType,
                                                NamespacePrefixMap nsMap)
                                         throws XSLException

  we're finished with adding attributes?

  Throws:
    `XSLException`

### endElementContent

    protected abstract void endElementContent(Name elementType)
                                       throws XSLException

  Throws:
    `XSLException`

### attribute

    public void attribute(Name name,
                          java.lang.String value)
                   throws XSLException

  construct an Attribute with the given name ... if we're not at an appropriate point, eg, we've already started putting text into an element, do nothing

  Specified by:
    `attribute` in interface `Result`
  Throws:
    `XSLException`

### start

    public void start(OutputMethod outputMethod)
               throws XSLException

  initialize, (and possibly construct) the DocumentHandler

  Specified by:
    `start` in interface `Result`
  Parameters:
    `outputMethod` - whatever the stylesheeet has told us about how it wants the trasnformed results output
  Throws:
    `XSLException`

### end

    public void end()
             throws XSLException

  flush any pending construction work, nothing else will be built

  Specified by:
    `end` in interface `Result`
  Throws:
    `XSLException`

### throwXSLException

    protected void throwXSLException(org.xml.sax.SAXException e)
                              throws XSLException

  Throws:
    `XSLException`

### resultTreeFragment

    public abstract void resultTreeFragment(ResultTreeFragment frag)
                                     throws XSLException

  Throws:
    `XSLException`

### message

    public void message(Node node,
                        java.lang.String str)
                 throws XSLException

  Description copied from interface: `Result`
  Support the `xsl:message` element.

  Specified by:
    `message` in interface `Result`
  Parameters:
    `node` - The source context node under consideration when the message action is performed. May be used for locator information
  Throws:
    `XSLException`

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