BEA Systems, Inc.

weblogicx.xml.tags
Class XsltTag

java.lang.Object
  extended by javax.servlet.jsp.tagext.TagSupport
      extended by javax.servlet.jsp.tagext.BodyTagSupport
          extended by weblogicx.xml.tags.XsltTag
All Implemented Interfaces:
Serializable, BodyTag, IterationTag, JspTag, Tag, EntityResolver

public class XsltTag
extends BodyTagSupport
implements EntityResolver

The XSL tag processes an XML string using the style sheet contained in the tag body or included from another servlet. You must specify a processor which are accessed through the generic Processor interface. Current implementations include xalan, xt, and saxon. Remember to specify text if you don't want all the extra XML version tags, etc.

See Also:
Serialized Form

Field Summary
 
Fields inherited from class javax.servlet.jsp.tagext.BodyTagSupport
bodyContent
 
Fields inherited from class javax.servlet.jsp.tagext.TagSupport
id, pageContext
 
Fields inherited from interface javax.servlet.jsp.tagext.BodyTag
EVAL_BODY_BUFFERED, EVAL_BODY_TAG
 
Fields inherited from interface javax.servlet.jsp.tagext.IterationTag
EVAL_BODY_AGAIN
 
Fields inherited from interface javax.servlet.jsp.tagext.Tag
EVAL_BODY_INCLUDE, EVAL_PAGE, SKIP_BODY, SKIP_PAGE
 
Constructor Summary
XsltTag()
           
 
Method Summary
 int doAfterBody()
           
 int doEndTag()
           
 int doStartTag()
           
 byte[] getContent(weblogic.servlet.internal.ServletRequestImpl request, String uri)
          Utility method for pulling content from another servlet.
protected  String getDefault()
           
 String getMedia()
           
protected  void getPIs(Node document)
           
 String getStylesheet()
           
 String getXml()
           
protected  String getXslPage(String media)
           
protected  Map parse(String data)
           
 Object putXslIs(String media, InputStream xslis)
           
 Object putXslURI(String media, String uri)
           
 void release()
          Release back to original state.
 InputSource resolveEntity(String pid, String sid)
          Entity resolver
protected  void setDefault(String defaultXslPage)
           
 void setDefaultXslIs(InputStream defaultXslIs)
           
 void setMedia(String media)
           
 void setStylesheet(String stylesheet)
           
 void setXml(String xml)
           
 void setXmlInputStream(InputStream xmlis)
           
 void setXslInputStream(InputStream xmlis)
           
 
Methods inherited from class javax.servlet.jsp.tagext.BodyTagSupport
doInitBody, getBodyContent, getPreviousOut, setBodyContent
 
Methods inherited from class javax.servlet.jsp.tagext.TagSupport
findAncestorWithClass, getId, getParent, getValue, getValues, removeValue, setId, setPageContext, setParent, setValue
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface javax.servlet.jsp.tagext.Tag
getParent, setPageContext, setParent
 

Constructor Detail

XsltTag

public XsltTag()
Method Detail

getXml

public String getXml()

setXml

public void setXml(String xml)

getMedia

public String getMedia()

setMedia

public void setMedia(String media)

getStylesheet

public String getStylesheet()

setStylesheet

public void setStylesheet(String stylesheet)

setXmlInputStream

public void setXmlInputStream(InputStream xmlis)

setXslInputStream

public void setXslInputStream(InputStream xmlis)

doStartTag

public int doStartTag()
               throws JspException
Specified by:
doStartTag in interface Tag
Overrides:
doStartTag in class BodyTagSupport
Throws:
JspException

doAfterBody

public int doAfterBody()
                throws JspException
Specified by:
doAfterBody in interface IterationTag
Overrides:
doAfterBody in class BodyTagSupport
Throws:
JspException

doEndTag

public int doEndTag()
             throws JspException
Specified by:
doEndTag in interface Tag
Overrides:
doEndTag in class BodyTagSupport
Throws:
JspException

setDefaultXslIs

public void setDefaultXslIs(InputStream defaultXslIs)

putXslIs

public Object putXslIs(String media,
                       InputStream xslis)

putXslURI

public Object putXslURI(String media,
                        String uri)

getDefault

protected String getDefault()

setDefault

protected void setDefault(String defaultXslPage)

getXslPage

protected String getXslPage(String media)

parse

protected Map parse(String data)

getPIs

protected void getPIs(Node document)
               throws SAXException
Throws:
SAXException

resolveEntity

public InputSource resolveEntity(String pid,
                                 String sid)
                          throws SAXException
Entity resolver

Specified by:
resolveEntity in interface EntityResolver
Throws:
SAXException

release

public void release()
Release back to original state.

Specified by:
release in interface Tag
Overrides:
release in class BodyTagSupport

getContent

public byte[] getContent(weblogic.servlet.internal.ServletRequestImpl request,
                         String uri)
                  throws IOException,
                         ServletException
Utility method for pulling content from another servlet.

Throws:
IOException
ServletException

Documentation is available at
http://download.oracle.com/docs/cd/E13222_01/wls/docs100
Copyright 2006 BEA Systems Inc.