UIX 2.2.16

oracle.cabo.ui.laf.icon
Class ContextImageIcon

java.lang.Object
  |
  +--oracle.cabo.ui.laf.icon.Icon
        |
        +--oracle.cabo.ui.laf.icon.BaseImageIcon
              |
              +--oracle.cabo.ui.laf.icon.ContextImageIcon

public class ContextImageIcon
extends BaseImageIcon

An Icon implementation for icons which are under the ServletContext root.


Constructor Summary
ContextImageIcon(java.lang.String uri, java.lang.Integer width, java.lang.Integer height)
          Creates a ContextImageIcon which uses the specified image URI regardless of the reading direction.
ContextImageIcon(java.lang.String uri, java.lang.String rtlURI, java.lang.Integer width, java.lang.Integer height)
          Creates an ContextImageIcon which has a different image URI depending on the reading direction.
ContextImageIcon(java.lang.String uri, java.lang.String rtlURI, java.lang.Integer width, java.lang.Integer height, java.lang.String styleClass, Style inlineStyle)
          Creates an ContextImageIcon which has a different image URI depending on the reading direction.
 
Method Summary
protected  java.lang.String getBaseURI(RenderingContext context)
          Implementation of BaseImageIcon.getBaseURI().
 InputStreamProvider getImageData(RenderingContext context)
          Override of Icon.getImageIcon().
 
Methods inherited from class oracle.cabo.ui.laf.icon.BaseImageIcon
getImageHeight, getImageURI, getImageWidth, getRelativeURI, renderIcon
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ContextImageIcon

public ContextImageIcon(java.lang.String uri,
                        java.lang.Integer width,
                        java.lang.Integer height)
Creates a ContextImageIcon which uses the specified image URI regardless of the reading direction.
Parameters:
uri - The URI to the image, relative to the servlet context root.
width - An Integer representing the width of the icon, or null if the width is not known.
height - An Integer representing the height of the icon, or null if the height is not known.

ContextImageIcon

public ContextImageIcon(java.lang.String uri,
                        java.lang.String rtlURI,
                        java.lang.Integer width,
                        java.lang.Integer height)
Creates an ContextImageIcon which has a different image URI depending on the reading direction.
Parameters:
uri - The URI of the left-to-right version of the image, relative to the servlet context root.
rtlURI - The URI of the right-to-left version of the image, relative to the servlet context root.
width - An Integer representing the width of the icon, or null if the width is not known.
height - An Integer representing the height of the icon, or null if the height is not known.

ContextImageIcon

public ContextImageIcon(java.lang.String uri,
                        java.lang.String rtlURI,
                        java.lang.Integer width,
                        java.lang.Integer height,
                        java.lang.String styleClass,
                        Style inlineStyle)
Creates an ContextImageIcon which has a different image URI depending on the reading direction.
Parameters:
uri - The URI of the left-to-right version of the image, relative to the servlet context root.
rtlURI - The URI of the right-to-left version of the image, relative to the servlet context root.
width - An Integer representing the width of the icon, or null if the width is not known.
height - An Integer representing the height of the icon, or null if the height is not known.
styleClass - The style class for the image icon
inlineStyle - The inline style for the image icon
Method Detail

getImageData

public InputStreamProvider getImageData(RenderingContext context)
                                 throws java.io.IOException
Override of Icon.getImageIcon().
Overrides:
getImageData in class Icon

getBaseURI

protected java.lang.String getBaseURI(RenderingContext context)
Implementation of BaseImageIcon.getBaseURI(). The base URI for ContextImageIcon is the ServletContext's base URI.
Overrides:
getBaseURI in class BaseImageIcon

UIX 2.2.16