Class ComputedCSSStyleDeclaration

  • All Implemented Interfaces:
    java.io.Serializable, java.lang.Cloneable, org.htmlunit.corejs.javascript.ConstProperties, org.htmlunit.corejs.javascript.debug.DebuggableObject, org.htmlunit.corejs.javascript.Scriptable, org.htmlunit.corejs.javascript.SymbolScriptable

    public class ComputedCSSStyleDeclaration
    extends CSSStyleDeclaration
    An object for a CSSStyleDeclaration, which is computed.
    See Also:
    Window.getComputedStyle(Object, String), Serialized Form
    • Field Detail

      • TO_STRING_TAG

        public static final java.lang.String TO_STRING_TAG
        Symbol.toStringTag support.
        See Also:
        Constant Field Values
    • Constructor Detail

      • ComputedCSSStyleDeclaration

        public ComputedCSSStyleDeclaration()
        Creates an instance.
    • Method Detail

      • jsConstructor

        public void jsConstructor()
        JavaScript constructor.
      • values

        public org.htmlunit.corejs.javascript.Scriptable values()
        Returns an Iterator allowing to go through all keys contained in this object. This method does nothing as the object is read-only.
        Overrides:
        values in class CSSStyleDeclaration
        Returns:
        a NativeArrayIterator
      • setStyleAttribute

        protected void setStyleAttribute​(java.lang.String name,
                                         java.lang.String newValue)
        Sets the specified style attribute. This method does nothing as the object is read-only.
        Overrides:
        setStyleAttribute in class CSSStyleDeclaration
        Parameters:
        name - the attribute name (camel-cased)
        newValue - the attribute value
      • getBackgroundAttachment

        public java.lang.String getBackgroundAttachment()
        Gets the backgroundAttachment style attribute.
        Overrides:
        getBackgroundAttachment in class CSSStyleDeclaration
        Returns:
        the style attribute
      • getBackgroundColor

        public java.lang.String getBackgroundColor()
        Gets the backgroundColor style attribute.
        Overrides:
        getBackgroundColor in class CSSStyleDeclaration
        Returns:
        the style attribute
      • getBackgroundImage

        public java.lang.String getBackgroundImage()
        Gets the backgroundImage style attribute.
        Overrides:
        getBackgroundImage in class CSSStyleDeclaration
        Returns:
        the style attribute
      • getBackgroundPosition

        public java.lang.String getBackgroundPosition()
        Gets the backgroundPosition style attribute.
        Overrides:
        getBackgroundPosition in class CSSStyleDeclaration
        Returns:
        the style attribute
      • getBackgroundRepeat

        public java.lang.String getBackgroundRepeat()
        Gets the backgroundRepeat style attribute.
        Overrides:
        getBackgroundRepeat in class CSSStyleDeclaration
        Returns:
        the style attribute
      • getBorderBottomColor

        public java.lang.String getBorderBottomColor()
        Gets the borderBottomColor style attribute.
        Overrides:
        getBorderBottomColor in class CSSStyleDeclaration
        Returns:
        the style attribute
      • getBorderBottomStyle

        public java.lang.String getBorderBottomStyle()
        Gets the borderBottomStyle style attribute.
        Overrides:
        getBorderBottomStyle in class CSSStyleDeclaration
        Returns:
        the style attribute
      • getBorderBottomWidth

        public java.lang.String getBorderBottomWidth()
        Gets the borderBottomWidth style attribute.
        Overrides:
        getBorderBottomWidth in class CSSStyleDeclaration
        Returns:
        the style attribute
      • getBorderLeftColor

        public java.lang.String getBorderLeftColor()
        Gets the borderLeftColor style attribute.
        Overrides:
        getBorderLeftColor in class CSSStyleDeclaration
        Returns:
        the style attribute
      • getBorderLeftStyle

        public java.lang.String getBorderLeftStyle()
        Gets the borderLeftStyle style attribute.
        Overrides:
        getBorderLeftStyle in class CSSStyleDeclaration
        Returns:
        the style attribute
      • getBorderLeftWidth

        public java.lang.String getBorderLeftWidth()
        Gets the borderLeftWidth style attribute.
        Overrides:
        getBorderLeftWidth in class CSSStyleDeclaration
        Returns:
        the style attribute
      • getBorderRightColor

        public java.lang.String getBorderRightColor()
        Gets the borderRightColor style attribute.
        Overrides:
        getBorderRightColor in class CSSStyleDeclaration
        Returns:
        the style attribute
      • getBorderRightStyle

        public java.lang.String getBorderRightStyle()
        Gets the borderRightStyle style attribute.
        Overrides:
        getBorderRightStyle in class CSSStyleDeclaration
        Returns:
        the style attribute
      • getBorderRightWidth

        public java.lang.String getBorderRightWidth()
        Gets the borderRightWidth style attribute.
        Overrides:
        getBorderRightWidth in class CSSStyleDeclaration
        Returns:
        the style attribute
      • getBorderTopColor

        public java.lang.String getBorderTopColor()
        Gets the borderTopColor style attribute.
        Overrides:
        getBorderTopColor in class CSSStyleDeclaration
        Returns:
        the style attribute
      • getBorderTopStyle

        public java.lang.String getBorderTopStyle()
        Gets the borderTopStyle style attribute.
        Overrides:
        getBorderTopStyle in class CSSStyleDeclaration
        Returns:
        the style attribute
      • getBorderTopWidth

        public java.lang.String getBorderTopWidth()
        Gets the borderTopWidth style attribute.
        Overrides:
        getBorderTopWidth in class CSSStyleDeclaration
        Returns:
        the style attribute
      • getBottom

        public java.lang.String getBottom()
        Gets the bottom style attribute.
        Overrides:
        getBottom in class CSSStyleDeclaration
        Returns:
        the style attribute
      • getColor

        public java.lang.String getColor()
        Gets the color style attribute.
        Overrides:
        getColor in class CSSStyleDeclaration
        Returns:
        the style attribute
      • getCssFloat

        public java.lang.String getCssFloat()
        Gets the cssFloat style attribute.
        Overrides:
        getCssFloat in class CSSStyleDeclaration
        Returns:
        the style attribute
      • getDisplay

        public java.lang.String getDisplay()
        Gets the display style attribute.
        Overrides:
        getDisplay in class CSSStyleDeclaration
        Returns:
        the style attribute
      • getFont

        public java.lang.String getFont()
        Gets the font style attribute.
        Overrides:
        getFont in class CSSStyleDeclaration
        Returns:
        the style attribute
      • getFontFamily

        public java.lang.String getFontFamily()
        Gets the fontFamily style attribute.
        Overrides:
        getFontFamily in class CSSStyleDeclaration
        Returns:
        the style attribute
      • getFontSize

        public java.lang.String getFontSize()
        Gets the fontSize style attribute.
        Overrides:
        getFontSize in class CSSStyleDeclaration
        Returns:
        the style attribute
      • getLineHeight

        public java.lang.String getLineHeight()
        Gets the lineHeight style attribute.
        Overrides:
        getLineHeight in class CSSStyleDeclaration
        Returns:
        the style attribute
      • getHeight

        public java.lang.String getHeight()
        Gets the height style attribute.
        Overrides:
        getHeight in class CSSStyleDeclaration
        Returns:
        the style attribute
      • getLeft

        public java.lang.String getLeft()
        Gets the left style attribute.
        Overrides:
        getLeft in class CSSStyleDeclaration
        Returns:
        the style attribute
      • getLetterSpacing

        public java.lang.String getLetterSpacing()
        Gets the letterSpacing style attribute.
        Overrides:
        getLetterSpacing in class CSSStyleDeclaration
        Returns:
        the style attribute
      • getMargin

        public java.lang.String getMargin()
        Gets the margin style attribute.
        Overrides:
        getMargin in class CSSStyleDeclaration
        Returns:
        the style attribute
      • getMarginBottom

        public java.lang.String getMarginBottom()
        Gets the marginBottom style attribute.
        Overrides:
        getMarginBottom in class CSSStyleDeclaration
        Returns:
        the style attribute
      • getMarginLeft

        public java.lang.String getMarginLeft()
        Gets the marginLeft style attribute.
        Overrides:
        getMarginLeft in class CSSStyleDeclaration
        Returns:
        the style attribute
      • getMarginRight

        public java.lang.String getMarginRight()
        Gets the marginRight style attribute.
        Overrides:
        getMarginRight in class CSSStyleDeclaration
        Returns:
        the style attribute
      • getMarginTop

        public java.lang.String getMarginTop()
        Gets the marginTop style attribute.
        Overrides:
        getMarginTop in class CSSStyleDeclaration
        Returns:
        the style attribute
      • getMaxHeight

        public java.lang.String getMaxHeight()
        Gets the maxHeight style attribute.
        Overrides:
        getMaxHeight in class CSSStyleDeclaration
        Returns:
        the style attribute
      • getMaxWidth

        public java.lang.String getMaxWidth()
        Gets the maxWidth style attribute.
        Overrides:
        getMaxWidth in class CSSStyleDeclaration
        Returns:
        the style attribute
      • getMinHeight

        public java.lang.String getMinHeight()
        Gets the minHeight style attribute.
        Overrides:
        getMinHeight in class CSSStyleDeclaration
        Returns:
        the style attribute
      • getMinWidth

        public java.lang.String getMinWidth()
        Gets the minWidth style attribute.
        Overrides:
        getMinWidth in class CSSStyleDeclaration
        Returns:
        the style attribute
      • getOpacity

        public java.lang.String getOpacity()
        Gets the opacity style attribute.
        Overrides:
        getOpacity in class CSSStyleDeclaration
        Returns:
        the style attribute
      • getOutlineWidth

        public java.lang.String getOutlineWidth()
        Gets the outlineWidth style attribute.
        Overrides:
        getOutlineWidth in class CSSStyleDeclaration
        Returns:
        the style attribute
      • getPadding

        public java.lang.String getPadding()
        Gets the padding style attribute.
        Overrides:
        getPadding in class CSSStyleDeclaration
        Returns:
        the style attribute
      • getPaddingBottom

        public java.lang.String getPaddingBottom()
        Gets the paddingBottom style attribute.
        Overrides:
        getPaddingBottom in class CSSStyleDeclaration
        Returns:
        the style attribute
      • getPaddingLeft

        public java.lang.String getPaddingLeft()
        Gets the paddingLeft style attribute.
        Overrides:
        getPaddingLeft in class CSSStyleDeclaration
        Returns:
        the style attribute
      • getPaddingRight

        public java.lang.String getPaddingRight()
        Gets the paddingRight style attribute.
        Overrides:
        getPaddingRight in class CSSStyleDeclaration
        Returns:
        the style attribute
      • getPaddingTop

        public java.lang.String getPaddingTop()
        Gets the paddingTop style attribute.
        Overrides:
        getPaddingTop in class CSSStyleDeclaration
        Returns:
        the style attribute
      • getRight

        public java.lang.String getRight()
        Gets the right style attribute.
        Overrides:
        getRight in class CSSStyleDeclaration
        Returns:
        the style attribute
      • getTextIndent

        public java.lang.String getTextIndent()
        Gets the textIndent style attribute.
        Overrides:
        getTextIndent in class CSSStyleDeclaration
        Returns:
        the style attribute
      • getTop

        public java.lang.String getTop()
        Gets the top style attribute.
        Overrides:
        getTop in class CSSStyleDeclaration
        Returns:
        the style attribute
      • getVerticalAlign

        public java.lang.String getVerticalAlign()
        Gets the verticalAlign style attribute.
        Overrides:
        getVerticalAlign in class CSSStyleDeclaration
        Returns:
        the style attribute
      • getWidows

        public java.lang.String getWidows()
        Gets the widows style attribute.
        Overrides:
        getWidows in class CSSStyleDeclaration
        Returns:
        the style attribute
      • getOrphans

        public java.lang.String getOrphans()
        Gets the orphans style attribute.
        Overrides:
        getOrphans in class CSSStyleDeclaration
        Returns:
        the style attribute
      • getPosition

        public java.lang.String getPosition()
        Gets the position style attribute.
        Overrides:
        getPosition in class CSSStyleDeclaration
        Returns:
        the style attribute
      • getWordSpacing

        public java.lang.String getWordSpacing()
        Gets the wordSpacing style attribute.
        Overrides:
        getWordSpacing in class CSSStyleDeclaration
        Returns:
        the style attribute
      • getZIndex

        public java.lang.Object getZIndex()
        Gets the zIndex style attribute.
        Overrides:
        getZIndex in class CSSStyleDeclaration
        Returns:
        the style attribute
      • getPropertyValue

        public java.lang.String getPropertyValue​(java.lang.String name)
        Gets the value of the specified property of the style.
        Overrides:
        getPropertyValue in class CSSStyleDeclaration
        Parameters:
        name - the style property name
        Returns:
        empty string if nothing found