Class Media

java.lang.Object
org.eclipse.e4.ui.css.core.impl.dom.Media

public final class Media extends Object
Media query model for @media rules.

The media types all and screen match, plus vendor features for the operating system, the windowing system, the operating system version and the installed bundles. Unknown types, features and values evaluate to false, as Media Queries requires.

  • Field Details

    • FEATURE_OS

      public static final String FEATURE_OS
      Feature naming the operating system, e.g. linux.
      See Also:
    • FEATURE_WS

      public static final String FEATURE_WS
      Feature naming the windowing system, e.g. gtk.
      See Also:
    • FEATURE_OS_VERSION

      public static final String FEATURE_OS_VERSION
      Feature naming the operating system version, e.g. "10.15".
      See Also:
    • FEATURE_MIN_OS_VERSION

      public static final String FEATURE_MIN_OS_VERSION
      Lower bound on the operating system version, inclusive.
      See Also:
    • FEATURE_MAX_OS_VERSION

      public static final String FEATURE_MAX_OS_VERSION
      Upper bound on the operating system version, inclusive.
      See Also:
    • FEATURE_BUNDLE

      public static final String FEATURE_BUNDLE
      Feature naming a bundle that has to be installed.
      See Also:
    • FEATURE_BUNDLE_VERSION

      public static final String FEATURE_BUNDLE_VERSION
      Feature naming a bundle and its version, e.g. "org.eclipse.ui 3.2".
      See Also:
    • FEATURE_MIN_BUNDLE_VERSION

      public static final String FEATURE_MIN_BUNDLE_VERSION
      Lower bound on a bundle's version, inclusive.
      See Also:
    • FEATURE_MAX_BUNDLE_VERSION

      public static final String FEATURE_MAX_BUNDLE_VERSION
      Upper bound on a bundle's version, inclusive.
      See Also:
  • Method Details

    • matches

      public static boolean matches(List<Media.Query> queries, Media.Context context)
      Whether a comma separated query list applies. Any query matching is enough, and an empty list matches everything.