Oracle UIX API Reference
Release 2.1.22.0.0
B12196-01

oracle.cabo.image.xml.parse
Class BaseImageProviderRequestParser

java.lang.Object
  |
  +--oracle.cabo.share.xml.BaseNodeParser
        |
        +--oracle.cabo.image.xml.parse.BaseImageProviderRequestParser
All Implemented Interfaces:
NodeParser
Direct Known Subclasses:
ButtonParser, ColorizedIconParser, DefaultsParser, FlippedIconParser, GlobalButtonParser, TabBarParser

public class BaseImageProviderRequestParser
extends BaseNodeParser

Base class for NodeParsers which parse ImageProviderRequests.

This class parses the following attributes:

It also parses the following elements


Constructor Summary
protected BaseImageProviderRequestParser(int capacity)
          Creates a NodeParser with enough storage to hold the number of ImageProviderRequest properties specified by capacity.
 
Method Summary
 void addCompletedChild(ParseContext context, java.lang.String namespaceURI, java.lang.String localName, java.lang.Object child)
          Implementation of NodeParser.addCompletedChild().
 java.lang.Object endElement(ParseContext context, java.lang.String namespaceURI, java.lang.String localName)
          Implementation of NodeParser.endElement()
protected  java.lang.Object getColorKey(java.lang.String namespaceURI, java.lang.String localName)
          Returns the key to use for storing the color associated with the specified element in the ImageProviderRequest.
protected  java.lang.Integer getDirection(ParseContext context, org.xml.sax.Attributes attrs)
          Gets the Integer value of the "direction" attribute.
protected  java.lang.String getEncodingType(ParseContext context, org.xml.sax.Attributes attrs)
          Gets the image encoding type.
protected  java.lang.Object getFontKey(java.lang.String namespaceURI, java.lang.String localName)
          Returns the key to use for storing the font associated with the specified element in the ImageProviderRequest.
protected  java.lang.Integer getHeight(ParseContext context, org.xml.sax.Attributes attrs)
          Gets the Integer value of the "height" attribute.
protected  java.lang.Integer getWidth(ParseContext context, org.xml.sax.Attributes attrs)
          Gets the Integer value of the "width" attribute.
protected  boolean isColorElement(java.lang.String namespaceURI, java.lang.String localName)
          Tests whether the specified element is a color.
protected  java.lang.Boolean isDisabled(ParseContext context, org.xml.sax.Attributes attrs)
          Gets the Boolean value of the "disabled" attribute.
protected  boolean isFontElement(java.lang.String namespaceURI, java.lang.String localName)
          Tests whether the specified element is a font.
protected  java.lang.Boolean isTextAntaliased(ParseContext context, org.xml.sax.Attributes attrs)
          Gets the boolean value of the "textAntialias" attribute.
protected  void setProperty(java.lang.Object key, java.lang.Object value)
          Sets a property to be included in the ImageProviderRequest
 NodeParser startChildElement(ParseContext context, java.lang.String namespaceURI, java.lang.String localName, org.xml.sax.Attributes attrs)
          Implementation of NodeParser.startChildElement()
 void startElement(ParseContext context, java.lang.String namespaceURI, java.lang.String localName, org.xml.sax.Attributes attrs)
          Implementation of NodeParser.startElement
 
Methods inherited from class oracle.cabo.share.xml.BaseNodeParser
addText, addWhitespace, endChildElement, getIgnoreParser, getRequiredAttribute, logError, logUnexpectedAttribute, logUnexpectedElement, logWarning, logWarning
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BaseImageProviderRequestParser

protected BaseImageProviderRequestParser(int capacity)
Creates a NodeParser with enough storage to hold the number of ImageProviderRequest properties specified by capacity.
Method Detail

startElement

public void startElement(ParseContext context,
                         java.lang.String namespaceURI,
                         java.lang.String localName,
                         org.xml.sax.Attributes attrs)
                  throws org.xml.sax.SAXParseException
Implementation of NodeParser.startElement
Overrides:
startElement in class BaseNodeParser
Following copied from interface: oracle.cabo.share.xml.NodeParser
Parameters:
context - the parsing context
namespaceURI - the namespace of the element
localName - the local name of the element
attrs - the attributes attached to the element

endElement

public java.lang.Object endElement(ParseContext context,
                                   java.lang.String namespaceURI,
                                   java.lang.String localName)
Implementation of NodeParser.endElement()
Overrides:
endElement in class BaseNodeParser
Following copied from interface: oracle.cabo.share.xml.NodeParser
Parameters:
context - the parsing context
namespaceURI - the namespace of the element
localName - the local name of the element
Returns:
the fully-initialized Java object corresponding to this release

startChildElement

public NodeParser startChildElement(ParseContext context,
                                    java.lang.String namespaceURI,
                                    java.lang.String localName,
                                    org.xml.sax.Attributes attrs)
Implementation of NodeParser.startChildElement()
Overrides:
startChildElement in class BaseNodeParser
Following copied from interface: oracle.cabo.share.xml.NodeParser
Parameters:
context - the parsing context
namespaceURI - the namespace of the child element
localName - the local name of the child element
attrs - the attributes attached to the element
Returns:
the node parser that should be used for this child element, or null if processing should continue with this NodeParser
See Also:
NodeParser.endChildElement(oracle.cabo.share.xml.ParseContext, java.lang.String, java.lang.String), NodeParser.addCompletedChild(oracle.cabo.share.xml.ParseContext, java.lang.String, java.lang.String, java.lang.Object)

addCompletedChild

public void addCompletedChild(ParseContext context,
                              java.lang.String namespaceURI,
                              java.lang.String localName,
                              java.lang.Object child)
Implementation of NodeParser.addCompletedChild().
Overrides:
addCompletedChild in class BaseNodeParser
Following copied from interface: oracle.cabo.share.xml.NodeParser
Parameters:
context - the parsing context
namespaceURI - the namespace of the child element
localName - the local name of the child element
child - the Java object produced for that child by its NodeParser's endElement() method.
See Also:
NodeParser.endElement(oracle.cabo.share.xml.ParseContext, java.lang.String, java.lang.String)

setProperty

protected void setProperty(java.lang.Object key,
                           java.lang.Object value)
Sets a property to be included in the ImageProviderRequest

isColorElement

protected boolean isColorElement(java.lang.String namespaceURI,
                                 java.lang.String localName)
Tests whether the specified element is a color. Subclasses should override this method to indicate that a specified element should be parsed to a Color. getColorKey() should also be overridden to return the ImageProviderRequest property key to use for any color element.

isFontElement

protected boolean isFontElement(java.lang.String namespaceURI,
                                java.lang.String localName)
Tests whether the specified element is a font. Subclasses should override this method to indicate that a specified element should be parsed to a FontProxy. getFontKey() should also be overridden to return the ImageProviderRequest property key to use for any font element.

getColorKey

protected java.lang.Object getColorKey(java.lang.String namespaceURI,
                                       java.lang.String localName)
Returns the key to use for storing the color associated with the specified element in the ImageProviderRequest.

getFontKey

protected java.lang.Object getFontKey(java.lang.String namespaceURI,
                                      java.lang.String localName)
Returns the key to use for storing the font associated with the specified element in the ImageProviderRequest.

isTextAntaliased

protected java.lang.Boolean isTextAntaliased(ParseContext context,
                                             org.xml.sax.Attributes attrs)
Gets the boolean value of the "textAntialias" attribute.

Returns null if the textAntialias attribute is not specified. Otherwise, returns a Boolean indicating the value of the textAntialias attribute.


isDisabled

protected java.lang.Boolean isDisabled(ParseContext context,
                                       org.xml.sax.Attributes attrs)
Gets the Boolean value of the "disabled" attribute.

Returns null if the disabled attribute is not specified. Otherwise, returns a Boolean indicating the value of the disabled attribute.


getWidth

protected java.lang.Integer getWidth(ParseContext context,
                                     org.xml.sax.Attributes attrs)
Gets the Integer value of the "width" attribute.

Returns null if the width attribute is not specified. Otherwise, returns an Integer indicating the value of the width attribute.


getHeight

protected java.lang.Integer getHeight(ParseContext context,
                                      org.xml.sax.Attributes attrs)
Gets the Integer value of the "height" attribute.

Returns null if the height attribute is not specified. Otherwise, returns an Integer indicating the value of the height attribute.


getDirection

protected java.lang.Integer getDirection(ParseContext context,
                                         org.xml.sax.Attributes attrs)
Gets the Integer value of the "direction" attribute.

Returns LocaleUtils.DIRECTION_RIGHTTOLEFT for "rtl" directions, LocaleUtils.DIRECTION_LEFTTORIGHT for "ltr" directions, or LocaleUtils.DIRECTION_DEFAULT if the direction is not specified.


getEncodingType

protected java.lang.String getEncodingType(ParseContext context,
                                           org.xml.sax.Attributes attrs)
Gets the image encoding type.

Returns one of the ImageEncoderManager.*_TYPE constants.


Oracle UIX API Reference
Release 2.1.22.0.0
B12196-01

Copyright © 2002,2003, Oracle. All Rights Reserved.