Interface MediaFeaturePredicate

All Superinterfaces:
BooleanCondition

public interface MediaFeaturePredicate extends BooleanCondition
Media Feature predicate.

Represents a predicate like (min-width: 600px) or (400px <= width < 1000px).

  • Method Details

    • getName

      String getName()
      Get the name of the feature.

      Example: width.

      Returns:
      the name of the feature.
    • setRangeType

      void setRangeType(byte rangeType)
      If the feature is of range type, set the range type as determined by the parser.
      Parameters:
      rangeType - the range type according to the implementation.
    • getRangeType

      byte getRangeType()
      Get the range type as was determined by the parser.
      Returns:
      the range type according to the implementation, or zero if not a range feature.
    • getValue

      Get the value to be tested on the feature. If the predicate involves two values, this is the first value.
      Returns:
      the value to be tested on the feature.
    • setValue

      void setValue(ExtendedCSSPrimitiveValue value)
      Set the value to be tested on the feature. If the predicate involves two values, this is the first value.
      Parameters:
      value - the value to be tested on the feature.
    • getRangeSecondValue

      ExtendedCSSPrimitiveValue getRangeSecondValue()
      If this is a range feature test involving two values, get the second value.
      Returns:
      the second value in this range test, or null if this is not a range feature or the range only involves one value.
    • setRangeSecondValue

      void setRangeSecondValue(ExtendedCSSPrimitiveValue value)
      Set the second value in this range test.
      Parameters:
      value - the second value in this range test.