Tree PREV CLASS NEXT CLASS SUMMARY: NESTED | FIELD | CONSTR | METHOD DETAIL: FIELD | CONSTR | METHOD com.ibm.portal.spa.parser.helper
Class DefaultStaticPageContentHandlerjava.lang.Objectcom.ibm.portal.spa.parser.helper.DefaultStaticPageContentHandler
- All Implemented Interfaces:
- StaticPageContentHandler, StaticPageContentHandlerEx
public class DefaultStaticPageContentHandler- extends java.lang.Object
- implements StaticPageContentHandler, StaticPageContentHandlerEx
Default implementation of a StaticPageContentHandler that simply ignores all events. This class is meant to be subclassed by real handlers.
- Since:
- 6.1.0
- Note:
This interface is designed to be implemented by clients.
Field Summary
Fields inherited from interface com.ibm.portal.spa.parser.StaticPageContentHandler ATTR_SCOPE, ATTR_SKIN, IWIDGET_DEFINITION
Constructor Summary DefaultStaticPageContentHandler()
Method Summary void anchorTag(java.lang.String url, org.xml.sax.Attributes atts)
Called for the Constants#ATTR_HREF attribute of a Constants#ELEMENT_A element.void baseTag(java.lang.String url, org.xml.sax.Attributes atts)
Called for the Constants#ATTR_HREF attribute of a Constants#ELEMENT_BASE element.void characters(char[] ch, int start, int length)
Signals a character sequence that does not contain any important semantic.void endBody()
Called right before the Constants#ELEMENT_BODY will be written.void endDocument()
Signaled after the parsing is complete.void endHead()
Called right before the Constants#ELEMENT_HEAD will be written.void endPortletContainer(java.lang.String name)
Signals the end of a portlet container.void endPortletWindow(java.lang.String name)
Signals the end of a portlet window.void imageTag(java.lang.String url, org.xml.sax.Attributes atts)
Called for the Constants#ATTR_SRC attribute of a Constants#ELEMENT_IMG element.void linkTag(java.lang.String url, org.xml.sax.Attributes atts)
Called for the Constants#ATTR_HREF attribute of a Constants#ELEMENT_LINK element.void metaTag(java.lang.String value, org.xml.sax.Attributes atts)
Called for the Constants#ATTR_CONTENT attribute of a Constants#ELEMENT_META element.void scriptTag(java.lang.String url, org.xml.sax.Attributes atts)
Called for the Constants#ATTR_HREF attribute of a Constants#ELEMENT_SCRIPT element.void startBody()
Called right after the Constants#ELEMENT_BODY element has been started.void startDocument(boolean bIsPageEmbedType)
Signaled before any other event is thrown.void startHead()
Called right after the Constants#ELEMENT_HEAD element has been started.void startPortletContainer(java.lang.String name, org.xml.sax.Attributes attrs)
Signals the start of a portlet container.org.xml.sax.ContentHandler startPortletWindow(java.lang.String name, java.lang.String definition, org.xml.sax.Attributes attrs)
Signals the start of a portlet window (or a different type of control).void titleTag(java.lang.String title, org.xml.sax.Attributes atts)
Called for the content of a Constants#ELEMENT_TITLE element.
Methods inherited from class java.lang.Object clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail DefaultStaticPageContentHandler
public DefaultStaticPageContentHandler()
Method Detail anchorTag
public void anchorTag(java.lang.String url, org.xml.sax.Attributes atts) throws java.io.IOException
- Description copied from interface: StaticPageContentHandlerEx
- Called for the Constants#ATTR_HREF attribute of a Constants#ELEMENT_A element. An implementation can use the StaticPageContentHandler.characters(char[], int, int) method to write a new escaped value. Without dispatching, the attribute in the output will be empty.
- Specified by:
- anchorTag in interface StaticPageContentHandlerEx
- Parameters:
- url - current value of the attribute in its escaped format
- atts - list of all available attributes
- Throws:
- java.io.IOException
baseTag
public void baseTag(java.lang.String url, org.xml.sax.Attributes atts) throws java.io.IOException
- Description copied from interface: StaticPageContentHandlerEx
- Called for the Constants#ATTR_HREF attribute of a Constants#ELEMENT_BASE element. An implementation can use the StaticPageContentHandler.characters(char[], int, int) method to write a new escaped value. Without dispatching, the attribute in the output will be empty.
- Specified by:
- baseTag in interface StaticPageContentHandlerEx
- Parameters:
- url - current value of the attribute in its escaped format
- atts - list of all available attributes
- Throws:
- java.io.IOException
characters
public void characters(char[] ch, int start, int length) throws java.io.IOException
- Description copied from interface: StaticPageContentHandler
- Signals a character sequence that does not contain any important semantic. This array must not be modified by the handler and must not be referenced outside of this method. The parser is free to reuse the same buffer for multiple character sequences.
- Specified by:
- characters in interface StaticPageContentHandler
- Parameters:
- ch - backing character array
- start - position of the first character in the array
- length - length of the valid sequence.
- Throws:
- java.io.IOException
endBody
public void endBody() throws java.io.IOException
- Description copied from interface: StaticPageContentHandlerEx
- Called right before the Constants#ELEMENT_BODY will be written. Implementations can override this method to inject content before ending the body.
- Specified by:
- endBody in interface StaticPageContentHandlerEx
- Throws:
- java.io.IOException
endDocument
public void endDocument() throws java.io.IOException
- Description copied from interface: StaticPageContentHandler
- Signaled after the parsing is complete.
- Specified by:
- endDocument in interface StaticPageContentHandler
- Throws:
- java.io.IOException
endHead
public void endHead() throws java.io.IOException
- Description copied from interface: StaticPageContentHandlerEx
- Called right before the Constants#ELEMENT_HEAD will be written. Implementations can override this method to inject content before ending the head.
- Specified by:
- endHead in interface StaticPageContentHandlerEx
- Throws:
- java.io.IOException
endPortletContainer
public void endPortletContainer(java.lang.String name) throws java.io.IOException
- Description copied from interface: StaticPageContentHandler
- Signals the end of a portlet container.
- Specified by:
- endPortletContainer in interface StaticPageContentHandler
- Parameters:
- name - name of the container, unique across the markup document
- Throws:
- java.io.IOException
endPortletWindow
public void endPortletWindow(java.lang.String name) throws java.io.IOException
- Description copied from interface: StaticPageContentHandler
- Signals the end of a portlet window.
- Specified by:
- endPortletWindow in interface StaticPageContentHandler
- Parameters:
- name - name of the window, unique across the markup document
- Throws:
- java.io.IOException
imageTag
public void imageTag(java.lang.String url, org.xml.sax.Attributes atts) throws java.io.IOException
- Description copied from interface: StaticPageContentHandlerEx
- Called for the Constants#ATTR_SRC attribute of a Constants#ELEMENT_IMG element. An implementation can use the StaticPageContentHandler.characters(char[], int, int) method to write a new escaped value. Without dispatching, the attribute in the output will be empty.
- Specified by:
- imageTag in interface StaticPageContentHandlerEx
- Parameters:
- url - current value of the attribute in its escaped format
- atts - list of all available attributes
- Throws:
- java.io.IOException
linkTag
public void linkTag(java.lang.String url, org.xml.sax.Attributes atts) throws java.io.IOException
- Description copied from interface: StaticPageContentHandlerEx
- Called for the Constants#ATTR_HREF attribute of a Constants#ELEMENT_LINK element. An implementation can use the StaticPageContentHandler.characters(char[], int, int) method to write a new escaped value. Without dispatching, the attribute in the output will be empty.
- Specified by:
- linkTag in interface StaticPageContentHandlerEx
- Parameters:
- url - current value of the attribute in its escaped format
- atts - list of all available attributes
- Throws:
- java.io.IOException
metaTag
public void metaTag(java.lang.String value, org.xml.sax.Attributes atts) throws java.io.IOException
- Description copied from interface: StaticPageContentHandlerEx
- Called for the Constants#ATTR_CONTENT attribute of a Constants#ELEMENT_META element. An implementation can use the StaticPageContentHandler.characters(char[], int, int) method to write a new escaped value. Without dispatching, the attribute in the output will be empty.
- Specified by:
- metaTag in interface StaticPageContentHandlerEx
- atts - list of all available attributes
- Throws:
- java.io.IOException
scriptTag
public void scriptTag(java.lang.String url, org.xml.sax.Attributes atts) throws java.io.IOException
- Description copied from interface: StaticPageContentHandlerEx
- Called for the Constants#ATTR_HREF attribute of a Constants#ELEMENT_SCRIPT element. An implementation can use the StaticPageContentHandler.characters(char[], int, int) method to write a new escaped value. Without dispatching, the attribute in the output will be empty.
- Specified by:
- scriptTag in interface StaticPageContentHandlerEx
- Parameters:
- url - current value of the attribute in its escaped format
- atts - list of all available attributes
- Throws:
- java.io.IOException
startBody
public void startBody() throws java.io.IOException
- Description copied from interface: StaticPageContentHandlerEx
- Called right after the Constants#ELEMENT_BODY element has been started. Implementations can override this method to inject content after the body.
- Specified by:
- startBody in interface StaticPageContentHandlerEx
- Throws:
- java.io.IOException
startDocument
public void startDocument(boolean bIsPageEmbedType) throws java.io.IOException
- Description copied from interface: StaticPageContentHandler
- Signaled before any other event is thrown. If the same handler instance is used multiple times each parsing process starts with this callback.
- Specified by:
- startDocument in interface StaticPageContentHandler
- Parameters:
- bIsPageEmbedType - true, if the parsed file contains html element. Otherwise return false.
- Throws:
- java.io.IOException
startHead
public void startHead() throws java.io.IOException
- Description copied from interface: StaticPageContentHandlerEx
- Called right after the Constants#ELEMENT_HEAD element has been started. Implementations can override this method to inject content after the body.
- Specified by:
- startHead in interface StaticPageContentHandlerEx
- Throws:
- java.io.IOException
startPortletContainer
public void startPortletContainer(java.lang.String name, org.xml.sax.Attributes attrs) throws java.io.IOException
- Description copied from interface: StaticPageContentHandler
- Signals the start of a portlet container.
- Specified by:
- startPortletContainer in interface StaticPageContentHandler
- Parameters:
- name - name of the container, unique across the markup document
- attrs - optional attribute map
- Throws:
- java.io.IOException
startPortletWindow
public org.xml.sax.ContentHandler startPortletWindow(java.lang.String name, java.lang.String definition, org.xml.sax.Attributes attrs) throws java.io.IOException
- Description copied from interface: StaticPageContentHandler
- Signals the start of a portlet window (or a different type of control). If iWidgets are contained on a page, they are also signaled via this method, the portlet definition contains the special identifier StaticPageContentHandler.IWIDGET_DEFINITION. The microformat is passed on to the ContentHandler that is returned by the method. List of known attributes:
- Specified by:
- startPortletWindow in interface StaticPageContentHandler
- Parameters:
- name - name of the window, unique across the markup document
- definition - identification of the portlet definition.
- attrs - optional attribute map
- Returns:
- an optional ContentHandler that receives events that describe the payload of the window.
- Throws:
- java.io.IOException
titleTag
public void titleTag(java.lang.String title, org.xml.sax.Attributes atts) throws java.io.IOException
- Description copied from interface: StaticPageContentHandlerEx
- Called for the content of a Constants#ELEMENT_TITLE element. An implementation can use the StaticPageContentHandler.characters(char[], int, int) method to write a new escaped value. Without dispatching, the value in the output will be empty.
- Specified by:
- titleTag in interface StaticPageContentHandlerEx
- Parameters:
- title - current value of the content in its escaped format
- atts - list of all available attributes
- Throws:
- java.io.IOException
Tree PREV CLASS NEXT CLASS SUMMARY: NESTED | FIELD | CONSTR | METHOD DETAIL: FIELD | CONSTR | METHOD