Class MozBackgroundSize
java.lang.Object
com.webfirmframework.wffweb.css.core.AbstractCssProperty<MozBackgroundSize>
com.webfirmframework.wffweb.css.css3.MozBackgroundSize
- All Implemented Interfaces:
CssProperty,Serializable,Cloneable
background-size: auto|length|cover|contain|initial|inherit; The background-size property specifies the size of the background images. Default value: auto Inherited: no Animatable: yes Version: CSS3 JavaScript syntax: object.style.mozBackgroundSize="60px 120px"
- Since:
- 1.0.0
- See Also:
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionThe0pxwill be set as the valueMozBackgroundSize(float horizontalHeight, CssLengthUnit cssLengthUnit) MozBackgroundSize(float width, CssLengthUnit widthCssLengthUnit, float height, CssLengthUnit heightCssLengthUnit) MozBackgroundSize(MozBackgroundSize backgroundSize) MozBackgroundSize(String cssValue) -
Method Summary
Modifier and TypeMethodDescriptiongets the vertical value in float value.getWidth()gets the horizontal value in float value.static booleanvalidates if the given cssValue is valid for this class.voidsets asinheritvoidsets asinitialsetCssValue(String cssValue) setValue(float widthHeight, CssLengthUnit cssLengthUnit) setValue(float width, CssLengthUnit widthCssLengthUnit, float height, CssLengthUnit heightCssLengthUnit) toString()Methods inherited from class com.webfirmframework.wffweb.css.core.AbstractCssProperty
clone, getStateChangeInformer, isAlreadyInUse, setAlreadyInUse, setStateChangeInformer, toCssString
-
Field Details
-
INITIAL
- See Also:
-
INHERIT
- See Also:
-
AUTO
- See Also:
-
COVER
- See Also:
-
CONTAIN
- See Also:
-
-
Constructor Details
-
MozBackgroundSize
public MozBackgroundSize()The0pxwill be set as the value -
MozBackgroundSize
- Parameters:
cssValue- the css value to set.
-
MozBackgroundSize
- Parameters:
backgroundSize- thebackgroundSizeobject from which the cssValue to set.And,nullwill throwNullValueException
-
MozBackgroundSize
- Parameters:
horizontalHeight- the value to set.cssLengthUnit- the value unit to set.- Since:
- 1.0.0
-
MozBackgroundSize
public MozBackgroundSize(float width, CssLengthUnit widthCssLengthUnit, float height, CssLengthUnit heightCssLengthUnit) - Parameters:
width-widthCssLengthUnit-height-heightCssLengthUnit-- Since:
- 1.0.0
-
-
Method Details
-
setValue
public MozBackgroundSize setValue(float width, CssLengthUnit widthCssLengthUnit, float height, CssLengthUnit heightCssLengthUnit) - Parameters:
width-widthCssLengthUnit-height-heightCssLengthUnit-- Returns:
- Since:
- 1.0.0
-
setValue
- Parameters:
widthHeight-cssLengthUnit-- Returns:
- the current object
- Since:
- 1.0.0
-
getCssName
- Returns:
- the name portion in style, eg
align-contentfor stylealign-content: center.
-
getCssValue
- Returns:
- the value portion in style, eg
centerfor stylealign-content: center.
-
toString
-
getWidth
gets the horizontal value in float value.BackgroundSize#getWidthUnit()should be used to get the cssLengthUnit for this value.- Returns:
- the horizontal value in float or
nullif the value is any inbuilt value likeinherit. - Since:
- 1.0.0
-
getHeight
gets the vertical value in float value.BackgroundSize#getHeightUnit()should be used to get the cssLengthUnit for this value.- Returns:
- the vertical value in float or
nullif the value is any inbuilt value likeinherit. - Since:
- 1.0.0
-
getWidthUnit
- Returns:
- the cssLengthUnit
PX/PER, ornullif the value is any inbuilt value likeinherit. - Since:
- 1.0.0
-
getHeightUnit
- Returns:
- the cssLengthUnit
PX/PER, ornullif the value is any inbuilt value likeinherit. - Since:
- 1.0.0
-
setCssValue
- Specified by:
setCssValuein classAbstractCssProperty<MozBackgroundSize>- Parameters:
cssValue- the value should be in the format of55pxor95%.nullis considered as an invalid value and it will throwNullValueException.- Returns:
- the current object.
- Since:
- 1.0.0
-
setAsInitial
public void setAsInitial()sets asinitial- Since:
- 1.0.0
-
setAsInherit
public void setAsInherit()sets asinherit- Since:
- 1.0.0
-
isValid
validates if the given cssValue is valid for this class.- Parameters:
cssValue- the value to check.- Returns:
- true if valid and false if invalid.
- Since:
- 1.0.0
-