Cookie

external interface Cookie

Interface that encapsulates all cookies interactions

Functions

Link copied to clipboard

Accept cookies

Link copied to clipboard

Decline cookies and delete existed once

Link copied to clipboard
abstract fun get(key: String, cookieAttribute: CookieAttribute = definedExternally): String?

Get cookie by key

Link copied to clipboard
Link copied to clipboard

Get preferred platform language code

Link copied to clipboard

Check if cookies are accepted by user

Link copied to clipboard
abstract fun remove(key: String, cookieAttribute: CookieAttribute = definedExternally)

Remove cookie

Link copied to clipboard
Link copied to clipboard
fun Cookie.saveLanguageCode(languageCode: String)

Save preferred platform language code

Link copied to clipboard
abstract fun set(key: String, value: String, cookieAttribute: CookieAttribute = definedExternally)

Set cookie

Link copied to clipboard
fun Cookie.set(key: CookieKeys, value: String)