[android-components](../../index.md) / [mozilla.components.browser.menu.item](../index.md) / [BrowserMenuHighlightableSwitch](index.md) / [asCandidate](./as-candidate.md)

# asCandidate

`fun asCandidate(context: <ERROR CLASS>): `[`CompoundMenuCandidate`](../../mozilla.components.concept.menu.candidate/-compound-menu-candidate/index.md) [(source)](https://github.com/mozilla-mobile/android-components/blob/master/components/browser/menu/src/main/java/mozilla/components/browser/menu/item/BrowserMenuHighlightableSwitch.kt#L81)

Overrides [BrowserMenuCompoundButton.asCandidate](../-browser-menu-compound-button/as-candidate.md)

Converts the menu item into a menu candidate.

