Enum Class BackgroundAttachment

java.lang.Object
java.lang.Enum<BackgroundAttachment>
com.oorian.css.BackgroundAttachment
All Implemented Interfaces:
Serializable, Comparable<BackgroundAttachment>, Constable

public enum BackgroundAttachment extends Enum<BackgroundAttachment>
CSS background-attachment property values for background scrolling behavior.

The background-attachment property sets whether a background image scrolls with the page content or remains fixed in the viewport.

Usage:


 element.setBackgroundAttachment(BackgroundAttachment.FIXED);
 element.setBackgroundAttachment(BackgroundAttachment.SCROLL);
 
Since:
2012
Version:
1.0
Author:
Marvin P. Warble Jr.
See Also:
  • Enum Constant Details

  • Method Details

    • values

      public static BackgroundAttachment[] values()
      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      public static BackgroundAttachment valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum class has no constant with the specified name
      NullPointerException - if the argument is null
    • getValue

      public String getValue()
      Returns the CSS value string.
      Returns:
      the CSS value
    • toString

      public String toString()
      Returns the CSS value string.
      Overrides:
      toString in class Enum<BackgroundAttachment>
      Returns:
      the CSS value