com.sapportals.portal.prt.util.html
Class HtmlImage

java.lang.Object
  |
  +--com.sapportals.portal.prt.util.html.HtmlAttributeContainer
        |
        +--com.sapportals.portal.prt.util.html.HtmlBase
              |
              +--com.sapportals.portal.prt.util.html.HtmlSinglePartElement
                    |
                    +--com.sapportals.portal.prt.util.html.HtmlImage
All Implemented Interfaces:
IHtmlAttributeContainer, IHtmlBase, IHtmlEventListener, IHtmlIdentifiable, IHtmlOutputable

public class HtmlImage
extends HtmlSinglePartElement
implements IHtmlEventListener, IHtmlIdentifiable

HtmlImage.java Created: Fri Oct 29 11:48:50 1999

Version:
$Revision: #3 $

Inner Class Summary
static class HtmlImage.ImageAlign
          The alignment of the image TOP|MIDDLE|BOTTOM
 
Field Summary
protected  HtmlImage.ImageAlign m_alignment
          The alignment of the image.
protected  java.lang.String m_alt
          text to show if you don't show the picture
protected  java.lang.String m_border
          The border around the picture
protected  java.lang.String m_height
          How tall is the image
protected  java.lang.String m_hSpace
          horizontal distance between the text and the image
protected  HtmlInlineScript m_onClick
          What to do when the user click on the form item.
protected  HtmlInlineScript m_onKeyDown
          What to do when a key is down.
protected  HtmlInlineScript m_onKeyPress
          What to do when a key is pressed.
protected  HtmlInlineScript m_onKeyUp
          What to do when a key is up.
protected  HtmlInlineScript m_onMouseOver
          What to do when the mouse is over.
protected  java.lang.String m_src
          Source of the image
protected  java.lang.String m_vSpace
          vertical distance between the text and the image
protected  java.lang.String m_width
          how wide is the image
 
Fields inherited from class com.sapportals.portal.prt.util.html.HtmlSinglePartElement
m_name
 
Fields inherited from class com.sapportals.portal.prt.util.html.HtmlBase
m_hasTag
 
Fields inherited from class com.sapportals.portal.prt.util.html.HtmlAttributeContainer
EQUALS_BEGIN, EQUALS_END, m_attributes, SPACE
 
Constructor Summary
HtmlImage()
           
HtmlImage(java.lang.String src)
           
 
Method Summary
 void destroy()
           
 HtmlImage.ImageAlign getAlignment()
          Get the value of m_alignment.
 java.lang.String getAlt()
          Get the value of m_alt.
 java.lang.String getBorder()
          Get the value of m_border.
 java.lang.String getHeight()
          Get the value of m_height.
 java.lang.String getHSpace()
          Get the value of m_hSpace.
 HtmlInlineScript getOnClick()
          Get the value of m_onClick.
 HtmlInlineScript getOnKeyDown()
          Get the value of m_onKeyDown.
 HtmlInlineScript getOnKeyPress()
          Get the value of m_onKeyPress.
 HtmlInlineScript getOnKeyUp()
          Get the value of m_onKeyUp.
 HtmlInlineScript getOnMouseOver()
          Get the value of m_onMouseOver.
 java.lang.String getSrc()
          Get the value of m_src.
 java.lang.String getVSpace()
          Get the value of m_vSpace.
 java.lang.String getWidth()
          Get the value of m_width.
 void outputAttributes(java.io.PrintWriter out)
          Deprecated.  
 void outputAttributes(java.lang.StringBuffer strbuf)
           
 void outputAttributes(java.io.Writer out)
           
 HtmlImage setAlignment(HtmlImage.ImageAlign v)
          Set the value of m_alignment.
 HtmlImage setAlt(java.lang.String v)
          Set the value of m_alt.
 HtmlImage setBorder(int v)
           
 HtmlImage setBorder(java.lang.String v)
          Set the value of m_border.
 void setClass(java.lang.String element_class)
          Set the element class for Cascading Style Sheets.
 HtmlImage setHeight(java.lang.String v)
          Set the value of m_height.
 HtmlImage setHSpace(java.lang.String v)
          Set the value of m_hSpace.
 void setID(java.lang.String id)
          Set the element id for Cascading Style Sheets.
 IHtmlEventListener setOnClick(HtmlInlineScript v)
          Set the value of m_onClick.
 IHtmlEventListener setOnKeyDown(HtmlInlineScript v)
          Set the value of m_onKeyDown.
 IHtmlEventListener setOnKeyPress(HtmlInlineScript v)
          Set the value of m_onKeyPress.
 IHtmlEventListener setOnKeyUp(HtmlInlineScript v)
          Set the value of m_onKeyUp.
 IHtmlEventListener setOnMouseOver(HtmlInlineScript v)
          Set the value of m_onMouseOver.
 HtmlImage setSrc(java.lang.String v)
          Set the value of m_src.
 HtmlImage setVSpace(java.lang.String v)
          Set the value of m_vSpace.
 HtmlImage setWidth(java.lang.String v)
          Set the value of m_width.
 
Methods inherited from class com.sapportals.portal.prt.util.html.HtmlSinglePartElement
getElementCount, getName, output, output, output, setName, toString
 
Methods inherited from class com.sapportals.portal.prt.util.html.HtmlBase
getTag, hasTag, requireClosingTag, requireClosingTag, setStyle, setTag
 
Methods inherited from class com.sapportals.portal.prt.util.html.HtmlAttributeContainer
addAttribute, appendToAttribute, getAttributes, removeAttribute
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

m_src

protected java.lang.String m_src
Source of the image

m_alignment

protected HtmlImage.ImageAlign m_alignment
The alignment of the image.

m_width

protected java.lang.String m_width
how wide is the image

m_height

protected java.lang.String m_height
How tall is the image

m_alt

protected java.lang.String m_alt
text to show if you don't show the picture

m_hSpace

protected java.lang.String m_hSpace
horizontal distance between the text and the image

m_vSpace

protected java.lang.String m_vSpace
vertical distance between the text and the image

m_border

protected java.lang.String m_border
The border around the picture

m_onKeyPress

protected HtmlInlineScript m_onKeyPress
What to do when a key is pressed.

m_onKeyDown

protected HtmlInlineScript m_onKeyDown
What to do when a key is down.

m_onKeyUp

protected HtmlInlineScript m_onKeyUp
What to do when a key is up.

m_onClick

protected HtmlInlineScript m_onClick
What to do when the user click on the form item.

m_onMouseOver

protected HtmlInlineScript m_onMouseOver
What to do when the mouse is over.
Constructor Detail

HtmlImage

public HtmlImage()

HtmlImage

public HtmlImage(java.lang.String src)
Method Detail

outputAttributes

public void outputAttributes(java.lang.StringBuffer strbuf)
Overrides:
outputAttributes in class HtmlAttributeContainer

outputAttributes

public void outputAttributes(java.io.PrintWriter out)
Deprecated.  

Overrides:
outputAttributes in class HtmlAttributeContainer
Following copied from interface: com.sapportals.portal.prt.util.html.IHtmlAttributeContainer
Parameters:
writer -  

outputAttributes

public void outputAttributes(java.io.Writer out)
Overrides:
outputAttributes in class HtmlAttributeContainer

setID

public void setID(java.lang.String id)
Set the element id for Cascading Style Sheets.
Specified by:
setID in interface IHtmlIdentifiable

setClass

public void setClass(java.lang.String element_class)
Set the element class for Cascading Style Sheets.
Specified by:
setClass in interface IHtmlIdentifiable
Overrides:
setClass in class HtmlBase

getSrc

public java.lang.String getSrc()
Get the value of m_src.
Returns:
Value of m_src.

setSrc

public HtmlImage setSrc(java.lang.String v)
Set the value of m_src.
Parameters:
v - Value to assign to m_src.

getAlignment

public HtmlImage.ImageAlign getAlignment()
Get the value of m_alignment.
Returns:
Value of m_alignment.

setAlignment

public HtmlImage setAlignment(HtmlImage.ImageAlign v)
Set the value of m_alignment.
Parameters:
v - Value to assign to m_alignment.

getWidth

public java.lang.String getWidth()
Get the value of m_width.
Returns:
Value of m_width.

setWidth

public HtmlImage setWidth(java.lang.String v)
Set the value of m_width.
Parameters:
v - Value to assign to m_width.

getHeight

public java.lang.String getHeight()
Get the value of m_height.
Returns:
Value of m_height.

setHeight

public HtmlImage setHeight(java.lang.String v)
Set the value of m_height.
Parameters:
v - Value to assign to m_height.

getAlt

public java.lang.String getAlt()
Get the value of m_alt.
Returns:
Value of m_alt.

setAlt

public HtmlImage setAlt(java.lang.String v)
Set the value of m_alt.
Parameters:
v - Value to assign to m_alt.

getHSpace

public java.lang.String getHSpace()
Get the value of m_hSpace.
Returns:
Value of m_hSpace.

setHSpace

public HtmlImage setHSpace(java.lang.String v)
Set the value of m_hSpace.
Parameters:
v - Value to assign to m_hSpace.

getVSpace

public java.lang.String getVSpace()
Get the value of m_vSpace.
Returns:
Value of m_vSpace.

setVSpace

public HtmlImage setVSpace(java.lang.String v)
Set the value of m_vSpace.
Parameters:
v - Value to assign to m_vSpace.

getBorder

public java.lang.String getBorder()
Get the value of m_border.
Returns:
Value of m_border.

setBorder

public HtmlImage setBorder(java.lang.String v)
Set the value of m_border.
Parameters:
v - Value to assign to m_border.

setBorder

public HtmlImage setBorder(int v)

getOnKeyPress

public HtmlInlineScript getOnKeyPress()
Get the value of m_onKeyPress.
Specified by:
getOnKeyPress in interface IHtmlEventListener
Returns:
Value of m_onKeyPress.

setOnKeyPress

public IHtmlEventListener setOnKeyPress(HtmlInlineScript v)
Set the value of m_onKeyPress.
Specified by:
setOnKeyPress in interface IHtmlEventListener
Parameters:
v - Value to assign to m_onKeyPress.

getOnKeyDown

public HtmlInlineScript getOnKeyDown()
Get the value of m_onKeyDown.
Specified by:
getOnKeyDown in interface IHtmlEventListener
Returns:
Value of m_onKeyDown.

setOnKeyDown

public IHtmlEventListener setOnKeyDown(HtmlInlineScript v)
Set the value of m_onKeyDown.
Specified by:
setOnKeyDown in interface IHtmlEventListener
Parameters:
v - Value to assign to m_onKeyDown.

getOnKeyUp

public HtmlInlineScript getOnKeyUp()
Get the value of m_onKeyUp.
Specified by:
getOnKeyUp in interface IHtmlEventListener
Returns:
Value of m_onKeyUp.

setOnKeyUp

public IHtmlEventListener setOnKeyUp(HtmlInlineScript v)
Set the value of m_onKeyUp.
Specified by:
setOnKeyUp in interface IHtmlEventListener
Parameters:
v - Value to assign to m_onKeyUp.

getOnClick

public HtmlInlineScript getOnClick()
Get the value of m_onClick.
Specified by:
getOnClick in interface IHtmlEventListener
Returns:
Value of m_onClick.

setOnClick

public IHtmlEventListener setOnClick(HtmlInlineScript v)
Set the value of m_onClick.
Specified by:
setOnClick in interface IHtmlEventListener
Parameters:
v - Value to assign to m_onClick.

getOnMouseOver

public HtmlInlineScript getOnMouseOver()
Get the value of m_onMouseOver.
Specified by:
getOnMouseOver in interface IHtmlEventListener
Returns:
Value of m_onMouseOver.

setOnMouseOver

public IHtmlEventListener setOnMouseOver(HtmlInlineScript v)
Set the value of m_onMouseOver.
Specified by:
setOnMouseOver in interface IHtmlEventListener
Parameters:
v - Value to assign to m_onMouseOver.

destroy

public void destroy()
Overrides:
destroy in class HtmlAttributeContainer