android-components / mozilla.components.browser.state.state / TabSessionState

TabSessionState

data class TabSessionState : SessionState (source)

Value type that represents the state of a tab (private or normal).

Constructors

Name Summary
<init> TabSessionState(id: String = UUID.randomUUID().toString(), content: ContentState, trackingProtection: TrackingProtectionState = TrackingProtectionState(), engineState: EngineState = EngineState(), parentId: String? = null, extensionState: Map<String, WebExtensionState> = emptyMap(), readerState: ReaderState = ReaderState())
Value type that represents the state of a tab (private or normal).

Properties

Name Summary
content val content: ContentState
the ContentState of this tab.
engineState val engineState: EngineState
the EngineState of this session.
extensionState val extensionState: Map<String, WebExtensionState>
a map of web extension ids to extensions, that contains the overridden values for this tab.
id val id: String
the ID of this tab and session.
parentId val parentId: String?
the parent ID of this tab or null if this tab has no parent. The parent tab is usually the tab that initiated opening this tab (e.g. the user clicked a link with target=”_blank” or selected “open in new tab” or a “window.open” was triggered).
readerState val readerState: ReaderState
the ReaderState of this tab.
trackingProtection val trackingProtection: TrackingProtectionState
the TrackingProtectionState of this tab.

Extension Functions

Name Summary
loadResourceAsString fun Any.loadResourceAsString(path: String): String
Loads a file from the resources folder and returns its content as a string object.