Liking cljdoc? Tell your friends :D

chromex.ext.sessions

clj

Use the chrome.sessions API to query and restore tabs and windows from a browsing session.

Use the chrome.sessions API to query and restore tabs and windows from a browsing session.

* available since Chrome 37
* https://developer.chrome.com/extensions/sessions
raw docstring

api-tableclj

source

gen-callclj

source

gen-wrapclj/smacro

(gen-wrap kind item-id config & args)
source

get-devicesclj/smacro

(get-devices)
(get-devices filter)

Retrieves all devices with synced sessions.

|filter| - https://developer.chrome.com/extensions/sessions#property-getDevices-filter.

This function returns a core.async channel of type promise-chan which eventually receives a result value. Signature of the result value put on the channel is [devices] where:

|devices| - The list of 'sessions.Device' objects for each synced session, sorted in order from device with most recently modified session to device with least recently modified session. 'tabs.Tab' objects are sorted by recency in the 'windows.Window' of the 'sessions.Session' objects.

In case of an error the channel closes without receiving any value and relevant error object can be obtained via chromex.error/get-last-error.

https://developer.chrome.com/extensions/sessions#method-getDevices.

Retrieves all devices with synced sessions.

  |filter| - https://developer.chrome.com/extensions/sessions#property-getDevices-filter.

This function returns a core.async channel of type `promise-chan` which eventually receives a result value.
Signature of the result value put on the channel is [devices] where:

  |devices| - The list of 'sessions.Device' objects for each synced session, sorted in order from device with most recently
              modified session to device with least recently modified session. 'tabs.Tab' objects are sorted by recency in
              the 'windows.Window' of the 'sessions.Session' objects.

In case of an error the channel closes without receiving any value and relevant error object can be obtained via
chromex.error/get-last-error.

https://developer.chrome.com/extensions/sessions#method-getDevices.
sourceraw docstring

get-devices*cljs

(get-devices* config filter)
source

get-max-session-resultsclj/smacro

(get-max-session-results)

The maximum number of 'sessions.Session' that will be included in a requested list.

https://developer.chrome.com/extensions/sessions#property-MAX_SESSION_RESULTS.

The maximum number of 'sessions.Session' that will be included in a requested list.

https://developer.chrome.com/extensions/sessions#property-MAX_SESSION_RESULTS.
sourceraw docstring

get-recently-closedclj/smacro

(get-recently-closed)
(get-recently-closed filter)

Gets the list of recently closed tabs and/or windows.

|filter| - https://developer.chrome.com/extensions/sessions#property-getRecentlyClosed-filter.

This function returns a core.async channel of type promise-chan which eventually receives a result value. Signature of the result value put on the channel is [sessions] where:

|sessions| - The list of closed entries in reverse order that they were closed (the most recently closed tab or window will be at index 0). The entries may contain either tabs or windows.

In case of an error the channel closes without receiving any value and relevant error object can be obtained via chromex.error/get-last-error.

https://developer.chrome.com/extensions/sessions#method-getRecentlyClosed.

Gets the list of recently closed tabs and/or windows.

  |filter| - https://developer.chrome.com/extensions/sessions#property-getRecentlyClosed-filter.

This function returns a core.async channel of type `promise-chan` which eventually receives a result value.
Signature of the result value put on the channel is [sessions] where:

  |sessions| - The list of closed entries in reverse order that they were closed (the most recently closed tab or window
               will be at index 0). The entries may contain either tabs or windows.

In case of an error the channel closes without receiving any value and relevant error object can be obtained via
chromex.error/get-last-error.

https://developer.chrome.com/extensions/sessions#method-getRecentlyClosed.
sourceraw docstring

get-recently-closed*cljs

(get-recently-closed* config filter)
source

max-session-results*cljs

(max-session-results* config)
source

on-changed*cljs

(on-changed* config channel & args)
source

restoreclj/smacro

(restore)
(restore session-id)

Reopens a 'windows.Window' or 'tabs.Tab', with an optional callback to run when the entry has been restored.

|session-id| - The 'windows.Window.sessionId', or 'tabs.Tab.sessionId' to restore. If this parameter is not specified, the most recently closed session is restored.

This function returns a core.async channel of type promise-chan which eventually receives a result value. Signature of the result value put on the channel is [restored-session] where:

|restored-session| - A 'sessions.Session' containing the restored 'windows.Window' or 'tabs.Tab' object.

In case of an error the channel closes without receiving any value and relevant error object can be obtained via chromex.error/get-last-error.

https://developer.chrome.com/extensions/sessions#method-restore.

Reopens a 'windows.Window' or 'tabs.Tab', with an optional callback to run when the entry has been restored.

  |session-id| - The 'windows.Window.sessionId', or 'tabs.Tab.sessionId' to restore. If this parameter is not specified,
                 the most recently closed session is restored.

This function returns a core.async channel of type `promise-chan` which eventually receives a result value.
Signature of the result value put on the channel is [restored-session] where:

  |restored-session| - A 'sessions.Session' containing the restored 'windows.Window' or 'tabs.Tab' object.

In case of an error the channel closes without receiving any value and relevant error object can be obtained via
chromex.error/get-last-error.

https://developer.chrome.com/extensions/sessions#method-restore.
sourceraw docstring

restore*cljs

(restore* config session-id)
source

tap-all-eventsclj/smacro

(tap-all-events chan)

Taps all valid non-deprecated events in chromex.ext.sessions namespace.

Taps all valid non-deprecated events in chromex.ext.sessions namespace.
sourceraw docstring

tap-on-changed-eventsclj/smacro

(tap-on-changed-events channel & args)

Fired when recently closed tabs and/or windows are changed. This event does not monitor synced sessions changes.

Events will be put on the |channel| with signature [::on-changed []].

Note: |args| will be passed as additional parameters into Chrome event's .addListener call.

https://developer.chrome.com/extensions/sessions#event-onChanged.

Fired when recently closed tabs and/or windows are changed. This event does not monitor synced sessions changes.

Events will be put on the |channel| with signature [::on-changed []].

Note: |args| will be passed as additional parameters into Chrome event's .addListener call.

https://developer.chrome.com/extensions/sessions#event-onChanged.
sourceraw docstring

cljdoc is a website building & hosting documentation for Clojure/Script libraries

× close