|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.steadystate.css.dom.CSSStyleDeclarationImpl
public class CSSStyleDeclarationImpl
| Constructor Summary | |
|---|---|
CSSStyleDeclarationImpl(CSSRule parentRule)
|
|
| Method Summary | |
|---|---|
void |
addProperty(Property p)
|
java.lang.String |
getCssText()
The parsable textual representation of the declaration block (excluding the surrounding curly braces). |
int |
getLength()
The number of properties that have been explicitly set in this declaration block. |
CSSRule |
getParentRule()
The CSS rule that contains this declaration block or null
if this CSSStyleDeclaration is not attached to a
CSSRule. |
CSSValue |
getPropertyCSSValue(java.lang.String propertyName)
Used to retrieve the object representation of the value of a CSS property if it has been explicitly set within this declaration block. |
java.lang.String |
getPropertyPriority(java.lang.String propertyName)
Used to retrieve the priority of a CSS property (e.g. |
java.lang.String |
getPropertyValue(java.lang.String propertyName)
Used to retrieve the value of a CSS property if it has been explicitly set within this declaration block. |
java.lang.String |
item(int index)
Used to retrieve the properties that have been explicitly set in this declaration block. |
java.lang.String |
removeProperty(java.lang.String propertyName)
Used to remove a CSS property if it has been explicitly set within this declaration block. |
void |
setCssText(java.lang.String cssText)
|
void |
setProperty(java.lang.String propertyName,
java.lang.String value,
java.lang.String priority)
Used to set a property value and priority within this declaration block. |
java.lang.String |
toString()
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public CSSStyleDeclarationImpl(CSSRule parentRule)
| Method Detail |
|---|
public java.lang.String getCssText()
CSSStyleDeclaration
getCssText in interface CSSStyleDeclaration
public void setCssText(java.lang.String cssText)
throws org.w3c.dom.DOMException
setCssText in interface CSSStyleDeclarationorg.w3c.dom.DOMExceptionpublic java.lang.String getPropertyValue(java.lang.String propertyName)
CSSStyleDeclaration
getPropertyValue in interface CSSStyleDeclarationpropertyName - The name of the CSS property. See the CSS property
index.
public CSSValue getPropertyCSSValue(java.lang.String propertyName)
CSSStyleDeclarationnull if the property is a shorthand
property. Shorthand property values can only be accessed and modified
as strings, using the getPropertyValue and
setProperty methods.
getPropertyCSSValue in interface CSSStyleDeclarationpropertyName - The name of the CSS property. See the CSS property
index.
null if the
property has not been set.
public java.lang.String removeProperty(java.lang.String propertyName)
throws org.w3c.dom.DOMException
CSSStyleDeclaration
removeProperty in interface CSSStyleDeclarationpropertyName - The name of the CSS property. See the CSS property
index.
org.w3c.dom.DOMException - NO_MODIFICATION_ALLOWED_ERR: Raised if this declaration is readonly
or the property is readonly.public java.lang.String getPropertyPriority(java.lang.String propertyName)
CSSStyleDeclaration"important" qualifier) if the property has been
explicitly set in this declaration block.
getPropertyPriority in interface CSSStyleDeclarationpropertyName - The name of the CSS property. See the CSS property
index.
"important") if one exists. The empty string if none
exists.
public void setProperty(java.lang.String propertyName,
java.lang.String value,
java.lang.String priority)
throws org.w3c.dom.DOMException
CSSStyleDeclaration
setProperty in interface CSSStyleDeclarationpropertyName - The name of the CSS property. See the CSS property
index.value - The new value of the property.priority - The new priority of the property (e.g.
"important").
org.w3c.dom.DOMException - SYNTAX_ERR: Raised if the specified value has a syntax error and is
unparsable.
public int getLength()
CSSStyleDeclaration
getLength in interface CSSStyleDeclarationpublic java.lang.String item(int index)
CSSStyleDeclaration
item in interface CSSStyleDeclarationindex - Index of the property name to retrieve.
public CSSRule getParentRule()
CSSStyleDeclarationnull
if this CSSStyleDeclaration is not attached to a
CSSRule.
getParentRule in interface CSSStyleDeclarationpublic void addProperty(Property p)
public java.lang.String toString()
toString in class java.lang.Object
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||