# ColorContrastOptions

[View Source](https://github.com/material-components/material-components-android/blob/1.14.0/lib/java/com/google/android/material/color/ColorContrastOptions.java)

*** ** * ** ***


```
public class ColorContrastOptions
```

<br />

*** ** * ** ***

Wrapper class for specifying color contrast options when applying contrast to branded and custom themes. Clients have the options to provide theme overlay resource ids for medium and high contrast mode.

An example of the provided theme overlay resource ids could be one of the following:

- contrast in light mode: R.style.ThemeOverlay_XxxContrast_Light
- contrast in dark mode: R.style.ThemeOverlay_XxxContrast_Dark
- contrast in both light and dark mode: R.style.ThemeOverlay_XxxContrast_DayNight

## Summary

| ### Nested types |
|---|
| `public class https://developer.android.com/reference/com/google/android/material/color/ColorContrastOptions.Builder` Builder class for specifying options when applying contrast. |

| ### Public methods |
|---|---|
| `int` | `https://developer.android.com/reference/com/google/android/material/color/ColorContrastOptions#getHighContrastThemeOverlay()()` Returns the resource id of the high contrast theme overlay. |
| `int` | `https://developer.android.com/reference/com/google/android/material/color/ColorContrastOptions#getMediumContrastThemeOverlay()()` Returns the resource id of the medium contrast theme overlay. |

## Public methods

### getHighContrastThemeOverlay

```
public int getHighContrastThemeOverlay()
```

Returns the resource id of the high contrast theme overlay.

### getMediumContrastThemeOverlay

```
public int getMediumContrastThemeOverlay()
```

Returns the resource id of the medium contrast theme overlay.