android-components / mozilla.components.browser.session / SessionManager / add

add

fun add(session: Session, selected: Boolean = false, engineSession: EngineSession? = null, engineSessionState: EngineSessionState? = null, parent: Session? = null): Unit (source)

Adds the provided session.

fun add(sessions: List<Session>): Unit (source)

Adds multiple sessions.

Note that for performance reasons this method will invoke SessionManager.Observer.onSessionsRestored and not SessionManager.Observer.onSessionAdded for every added Session.