com.filenet.wcm.toolkit.server.util.ui
Class WcmIconAnchor

java.lang.Object
  extended bycom.filenet.wcm.toolkit.server.util.ui.WcmAnchor
      extended bycom.filenet.wcm.toolkit.server.util.ui.WcmIconAnchor

public class WcmIconAnchor
extends WcmAnchor

This class extends the base WcmAnchor and implements an icon anchor.


Field Summary
protected  java.lang.String altImageLabel
          The label of the HTML image alt attribute.
protected  java.lang.String iconURL
          The icon url path.
protected  java.lang.String imageAttributes
          Any additional image HTML attributes.
 
Fields inherited from class com.filenet.wcm.toolkit.server.util.ui.WcmAnchor
disabled, extraAttributes, hidden, id, label, locLabel, onClick, onContextMenu, popup, toolTip, urlObject, urlString, windowHeight, windowWidth
 
Constructor Summary
WcmIconAnchor(java.lang.String url, java.lang.String iconURL)
          Contructs a new WcmIconAnchor object without any label.
WcmIconAnchor(java.lang.String url, java.lang.String label, java.lang.String iconURL)
          Contructs a new WcmIconAnchor object.
WcmIconAnchor(java.lang.String url, WcmString localizedLabel, java.lang.String iconURL)
          Contructs a new WcmIconAnchor object.
WcmIconAnchor(java.lang.String url, WcmString localizedLabel, java.lang.String iconURL, java.util.Locale locale)
          Contructs a new WcmIconAnchor object.
 
Method Summary
static WcmIconAnchor createNonLocalized(java.lang.String url, java.lang.String label, java.lang.String iconURL)
          Deprecated. Use the constructor.
 java.lang.String getAltImageLabel()
          Returns the alt label of the icon.
 java.lang.String getHTML()
          Returns the WcmIconAnchor HTML.
 java.lang.String getHTML(java.lang.String imageAttributes)
          Returns the WcmIconAnchor HTML.
 java.lang.String getHTML(java.lang.String anchorAttributes, java.lang.String imageAttributes)
          Returns the WcmIconAnchor HTML.
 java.lang.String getIconUrl()
          Returns the icon url path.
 java.lang.String getImageElementHTML()
          Returns the image HTML.
 java.lang.String getImageElementHTML(java.lang.String imageAttributes)
          Returns the image HTML of the icon.
 boolean isImageDefined()
          Returns true when an image is defined.
 void setAltImageLabel(WcmString localizedAltImageLabel)
          Sets the icon alt label.
 
Methods inherited from class com.filenet.wcm.toolkit.server.util.ui.WcmAnchor
createNonLocalized, getCloseTagHTML, getHTML, getHTML, getId, getLabel, getLabel, getOpenTagHTML, getOpenTagHTML, getToolTip, getURL, getWindowHeight, getWindowWidth, isDisabled, isHidden, isPopup, setDisabled, setHidden, setId, setNonLocalizedLabel, setOnClick, setOnContextMenu, setPopup, setToolTip, setToolTip, setToolTip, setURL, setURL, setWindowHeight, setWindowWidth, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

iconURL

protected java.lang.String iconURL
The icon url path.


altImageLabel

protected java.lang.String altImageLabel
The label of the HTML image alt attribute.


imageAttributes

protected java.lang.String imageAttributes
Any additional image HTML attributes.

Constructor Detail

WcmIconAnchor

public WcmIconAnchor(java.lang.String url,
                     java.lang.String label,
                     java.lang.String iconURL)
Contructs a new WcmIconAnchor object.

Parameters:
url - The url string of the new anchor.
label - The localized label of the new anchor.
iconURL - The icon url path.

WcmIconAnchor

public WcmIconAnchor(java.lang.String url,
                     WcmString localizedLabel,
                     java.lang.String iconURL)
Contructs a new WcmIconAnchor object.

Parameters:
url - The url string of the new anchor.
localizedLabel - The localized label of the new anchor.
iconURL - The icon url path.

WcmIconAnchor

public WcmIconAnchor(java.lang.String url,
                     WcmString localizedLabel,
                     java.lang.String iconURL,
                     java.util.Locale locale)
Contructs a new WcmIconAnchor object.

Parameters:
url - The url string of the new anchor.
localizedLabel - The localized label of the new anchor.
iconURL - The icon url path.
locale - client locale

WcmIconAnchor

public WcmIconAnchor(java.lang.String url,
                     java.lang.String iconURL)
Contructs a new WcmIconAnchor object without any label.

Parameters:
url - The url string of the new anchor.
iconURL - The icon url path.
Method Detail

createNonLocalized

public static WcmIconAnchor createNonLocalized(java.lang.String url,
                                               java.lang.String label,
                                               java.lang.String iconURL)
Deprecated. Use the constructor.

Creates a new non localized WcmIconAnchor object.

Parameters:
url - The url string of the new anchor.
label - The label of the new anchor.
iconURL - The icon url path.
Returns:
WcmAnchor A new WcmAnchor object.

getHTML

public java.lang.String getHTML(java.lang.String imageAttributes)
Returns the WcmIconAnchor HTML.

Overrides:
getHTML in class WcmAnchor
Parameters:
imageAttributes - Any additional image tag attributes.
Returns:
String The WcmIconAnchor HTLM.

getHTML

public java.lang.String getHTML(java.lang.String anchorAttributes,
                                java.lang.String imageAttributes)
Returns the WcmIconAnchor HTML.

Parameters:
anchorAttributes - Any additional anchor HTML attributes. For a disabled anchor, the extra attributes will be added to the <span> tag. Otherwise, it is added to the <a> tag.
imageAttributes - Any additional image tag attributes.
Returns:
String The WcmIconAnchor HTLM.

getHTML

public java.lang.String getHTML()
Returns the WcmIconAnchor HTML.

Overrides:
getHTML in class WcmAnchor
Returns:
String The WcmIconAnchor HTLM.

getImageElementHTML

public java.lang.String getImageElementHTML(java.lang.String imageAttributes)
Returns the image HTML of the icon.

Parameters:
imageAttributes - Any additional image tag attributes.
Returns:
String The image HTLM for the icon.

getImageElementHTML

public java.lang.String getImageElementHTML()
Returns the image HTML.

Returns:
String The image HTLM for the icon.

setAltImageLabel

public void setAltImageLabel(WcmString localizedAltImageLabel)
Sets the icon alt label.

Parameters:
localizedAltImageLabel - The localized label being used for the icon alt label.

getAltImageLabel

public java.lang.String getAltImageLabel()
Returns the alt label of the icon.

Returns:
String The alt label.

getIconUrl

public java.lang.String getIconUrl()
Returns the icon url path.

Returns:
String The icon url path.

isImageDefined

public boolean isImageDefined()
Returns true when an image is defined. Otherwise returns false.

Returns:
boolean true or false.


© Copyright IBM Corp. 2002, 2007. All Rights Reserved.