public abstract class AbstractCssStyleDeclaration extends Object implements Serializable
| Constructor and Description | 
|---|
| AbstractCssStyleDeclaration() | 
| Modifier and Type | Method and Description | 
|---|---|
| String | getBackgroundAttachment()Gets the  backgroundAttachmentstyle attribute. | 
| String | getBackgroundColor()Gets the  backgroundColorstyle attribute. | 
| String | getBackgroundImage()Gets the  backgroundImagestyle attribute. | 
| String | getBackgroundPosition()Gets the  backgroundPositionstyle attribute. | 
| String | getBackgroundRepeat()Gets the  backgroundRepeatstyle attribute. | 
| String | getBlockSize()Gets the  blockSizestyle attribute. | 
| String | getBorderBottomColor()Gets the  borderBottomColorstyle attribute. | 
| String | getBorderBottomStyle()Gets the  borderBottomStylestyle attribute. | 
| String | getBorderBottomWidth()Gets the  borderBottomWidthstyle attribute. | 
| String | getBorderLeftColor()Gets the  borderLeftColorstyle attribute. | 
| String | getBorderLeftStyle()Gets the  borderLeftStylestyle attribute. | 
| String | getBorderLeftWidth()Gets the  borderLeftWidthstyle attribute. | 
| String | getBorderRightColor()Gets the  borderRightColorstyle attribute. | 
| String | getBorderRightStyle()Gets the  borderRightStylestyle attribute. | 
| String | getBorderRightWidth()Gets the  borderRightWidthstyle attribute. | 
| String | getBorderTop()Gets the  borderTopstyle attribute. | 
| String | getBorderTopColor()Gets the  borderTopColorstyle attribute. | 
| String | getBorderTopStyle()Gets the  borderTopStylestyle attribute. | 
| String | getBorderTopWidth()Gets the  borderTopWidthstyle attribute. | 
| String | getBottom()Gets the  bottomstyle attribute. | 
| abstract BrowserVersion | getBrowserVersion() | 
| String | getColor()Gets the  colorstyle attribute. | 
| String | getCssFloat()Gets the  cssFloatstyle attribute. | 
| abstract String | getCssText()Returns the actual text of the style. | 
| String | getDisplay()Gets the  displaystyle attribute. | 
| String | getFont()Gets the  fontstyle attribute. | 
| String | getFontFamily()Gets the  fontFamilystyle attribute. | 
| String | getFontSize()Gets the  fontSizestyle attribute. | 
| String | getHeight()Gets the  heightstyle attribute. | 
| String | getLeft() | 
| abstract int | getLength()Returns the  lengthproperty. | 
| String | getLetterSpacing() | 
| String | getLineHeight() | 
| String | getMargin() | 
| String | getMarginBottom()Gets the  marginBottomstyle attribute. | 
| String | getMarginLeft()Gets the  marginLeftstyle attribute. | 
| String | getMarginRight()Gets the  marginRightstyle attribute. | 
| String | getMarginTop()Gets the  marginTopstyle attribute. | 
| String | getMaxHeight() | 
| String | getMaxWidth() | 
| String | getMinHeight() | 
| String | getMinWidth() | 
| String | getOpacity()Gets the  opacitystyle attribute. | 
| String | getOrphans() | 
| String | getOutline() | 
| String | getOutlineWidth() | 
| String | getPadding() | 
| String | getPaddingBottom() | 
| String | getPaddingLeft() | 
| String | getPaddingRight() | 
| String | getPaddingTop() | 
| abstract org.htmlunit.cssparser.dom.AbstractCSSRuleImpl | getParentRule()Returns the CSSRule that is the parent of this style block or  nullif this CSSStyleDeclaration is
 not attached to a CSSRule. | 
| String | getPosition() | 
| String | getRight() | 
| String | getRubyAlign() | 
| String | getSize() | 
| abstract String | getStyleAttribute(String name)Get the value for the style attribute. | 
| abstract String | getStyleAttribute(StyleAttributes.Definition definition,
                 boolean getDefaultValueIfEmpty)Get the value for the style attribute. | 
| String | getStyleAttribute(StyleAttributes.Definition definition1,
                 StyleAttributes.Definition definition2)Returns the value of one of the two named style attributes. | 
| abstract StyleElement | getStyleElement(String name)Determines the StyleElement for the given name. | 
| abstract StyleElement | getStyleElementCaseInSensitive(String name)Determines the StyleElement for the given name. | 
| abstract Map<String,StyleElement> | getStyleMap()Returns a sorted map containing style elements, keyed on style element name. | 
| abstract String | getStylePriority(String name)Returns the priority of the named style attribute, or an empty string if it is not found. | 
| String | getTextIndent() | 
| String | getTop() | 
| String | getVerticalAlign() | 
| String | getWidows() | 
| String | getWidth() | 
| String | getWordSpacing() | 
| String | getZIndex()Gets the  zIndexstyle attribute. | 
| abstract boolean | hasFeature(BrowserVersionFeatures property)Indicates if the browser this is associated with has the feature. | 
| boolean | isComputed() | 
| abstract String | item(int index) | 
| abstract String | removeStyleAttribute(String name)Removes the specified style attribute, returning the value of the removed attribute. | 
| abstract void | setCssText(String value)Sets the actual text of the style. | 
| abstract void | setStyleAttribute(String name,
                 String newValue,
                 String important)Sets the specified style attribute. | 
public abstract String getStylePriority(String name)
name - the name of the style attribute whose value is to be retrievedpublic abstract String getCssText()
public abstract String getStyleAttribute(String name)
name - the namepublic abstract String getStyleAttribute(StyleAttributes.Definition definition, boolean getDefaultValueIfEmpty)
ComputedCssStyleDeclaration.definition - the definitiongetDefaultValueIfEmpty - whether to get the default value if empty or notpublic abstract boolean hasFeature(BrowserVersionFeatures property)
property - the property namefalse if this browser doesn't have this featurepublic abstract BrowserVersion getBrowserVersion()
BrowserVersionpublic String getStyleAttribute(StyleAttributes.Definition definition1, StyleAttributes.Definition definition2)
Returns the value of one of the two named style attributes. If both attributes exist, the value of the attribute that was declared last is returned. If only one of the attributes exists, its value is returned. If neither attribute exists, an empty string is returned.
The second named attribute may be shorthand for the actual desired property. The following formats are possible:
top right bottom left: All values are explicit.top right bottom: Left is implicitly the same as right.top right: Left is implicitly the same as right, bottom is implicitly the same as top.top: Left, bottom and right are implicitly the same as top.definition1 - the name of the first style attributedefinition2 - the name of the second style attributepublic abstract void setCssText(String value)
value - the new textpublic abstract void setStyleAttribute(String name, String newValue, String important)
name - the attribute name (camel-cased)newValue - the attribute valueimportant - important valuepublic abstract String removeStyleAttribute(String name)
name - the attribute name (delimiter-separated, not camel-cased)public abstract int getLength()
length property.length propertypublic abstract String item(int index)
index - the indexpublic abstract org.htmlunit.cssparser.dom.AbstractCSSRuleImpl getParentRule()
null if this CSSStyleDeclaration is
 not attached to a CSSRule.null if this CSSStyleDeclaration is
      not attached to a CSSRulepublic abstract StyleElement getStyleElement(String name)
name - the name of the requested StyleElementpublic abstract StyleElement getStyleElementCaseInSensitive(String name)
name - the name of the requested StyleElementpublic abstract Map<String,StyleElement> getStyleMap()
LinkedHashMap map so that results are deterministic and are thus testable.public boolean isComputed()
public String getBackgroundAttachment()
backgroundAttachment style attribute.public String getBackgroundColor()
backgroundColor style attribute.public String getBackgroundImage()
backgroundImage style attribute.public String getBackgroundPosition()
backgroundPosition style attribute.public String getBackgroundRepeat()
backgroundRepeat style attribute.public String getBlockSize()
blockSize style attribute.public String getBorderBottomColor()
borderBottomColor style attribute.public String getBorderBottomStyle()
borderBottomStyle style attribute.public String getBorderBottomWidth()
borderBottomWidth style attribute.public String getBorderLeftColor()
borderLeftColor style attribute.public String getBorderLeftStyle()
borderLeftStyle style attribute.public String getBorderLeftWidth()
borderLeftWidth style attribute.public String getBorderRightColor()
borderRightColor style attribute.public String getBorderRightStyle()
borderRightStyle style attribute.public String getBorderRightWidth()
borderRightWidth style attribute.public String getBorderTop()
borderTop style attribute.public String getBorderTopColor()
borderTopColor style attribute.public String getBorderTopStyle()
borderTopStyle style attribute.public String getBorderTopWidth()
borderTopWidth style attribute.public String getBottom()
bottom style attribute.public String getColor()
color style attribute.public String getCssFloat()
cssFloat style attribute.public String getDisplay()
display style attribute.public String getFont()
font style attribute.public String getFontFamily()
fontFamily style attribute.public String getFontSize()
fontSize style attribute.public String getHeight()
height style attribute.public String getLeft()
leftpublic String getLetterSpacing()
letterSpacingpublic String getLineHeight()
lineHeightpublic String getMargin()
marginpublic String getMarginBottom()
marginBottom style attribute.public String getMarginLeft()
marginLeft style attribute.public String getMarginRight()
marginRight style attribute.public String getMarginTop()
marginTop style attribute.public String getMaxHeight()
maxHeightpublic String getMaxWidth()
maxWidthpublic String getMinHeight()
minHeightpublic String getMinWidth()
minWidthpublic String getOpacity()
opacity style attribute.public String getOrphans()
orphanspublic String getOutline()
outlinepublic String getOutlineWidth()
outlineWidthpublic String getPadding()
paddingpublic String getPaddingBottom()
paddingBottompublic String getPaddingLeft()
paddingLeftpublic String getPaddingRight()
paddingRightpublic String getPaddingTop()
paddingToppublic String getPosition()
positionpublic String getRight()
rightpublic String getRubyAlign()
rubyAlignpublic String getSize()
sizepublic String getTextIndent()
textIndentpublic String getTop()
toppublic String getVerticalAlign()
verticalAlignpublic String getWidows()
widowspublic String getWidth()
widthpublic String getWordSpacing()
wordSpacingpublic String getZIndex()
zIndex style attribute.Copyright © 2002–2025 Gargoyle Software Inc.. All rights reserved.