echopointng.command
Class CssStyleAddValues

java.lang.Object
  extended by echopointng.command.CssStyleAddValues
All Implemented Interfaces:
Command

public class CssStyleAddValues
extends java.lang.Object
implements Command

CssStyleAddValues allows form an arbitary CSS style values to be added to a component on the client browser.

If a given CSS value currently exists, it is replaced, otherwise it is appended.

For example given the XHTML declaration :

 
  
                <div style="background-color:red" >...</div> 
   
  
 
The new CssStyleAddValues("background-color:blue;font-size:8pt",myComponent) will result in the new XHTML declaration of :
 
  
                <div style="background-color:blue;font-size:8pt;" >...</div> 
   
  
 


Constructor Summary
CssStyleAddValues(java.lang.String styleText, Component targetComponent)
          Constructs a CssStyleAddValues command with the text of a CSS style declaration and the component to apply it to.
 
Method Summary
 java.lang.String getStyleText()
           
 Component getTargetComponent()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CssStyleAddValues

public CssStyleAddValues(java.lang.String styleText,
                         Component targetComponent)
Constructs a CssStyleAddValues command with the text of a CSS style declaration and the component to apply it to. For example given the XHTML declaration :
 
  
                <div style="background-color:red" >...</div> 
   
  
 
Then new CssStyleAddValues("background-color:blue;font-size:8pt",myComponent) will result in the new XHTML declaration of :
 
  
                <div style="background-color:blue;font-size:8pt;" >...</div> 
   
  
 

Parameters:
styleText - - the text of the style declarartion
targetComponent - - the target component to apply the style values to
Method Detail

getStyleText

public java.lang.String getStyleText()
Returns:
Returns the CSS style declaration text

getTargetComponent

public Component getTargetComponent()
Returns:
Returns the targetComponent.