Liking cljdoc? Tell your friends :D

chromex.ext.vpn-provider

clj

Use the chrome.vpnProvider API to implement a VPN client.

Use the chrome.vpnProvider API to implement a VPN
client.

  * available since Chrome 43
  * https://developer.chrome.com/extensions/vpnProvider
raw docstring

api-tableclj

source

create-configclj/smacro

(create-config name)

Creates a new VPN configuration that persists across multiple login sessions of the user.

|name| - The name of the VPN configuration.

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 [id] where:

|id| - A unique ID for the created configuration, or undefined on failure.

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/vpnProvider#method-createConfig.

Creates a new VPN configuration that persists across multiple login sessions of the user.

  |name| - The name of the VPN configuration.

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 [id] where:

  |id| - A unique ID for the created configuration, or undefined on failure.

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/vpnProvider#method-createConfig.
sourceraw docstring

create-config*cljs

(create-config* config name)
source

destroy-configclj/smacro

(destroy-config id)

Destroys a VPN configuration created by the extension.

|id| - ID of the VPN configuration to destroy.

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 [].

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/vpnProvider#method-destroyConfig.

Destroys a VPN configuration created by the extension.

  |id| - ID of the VPN configuration to destroy.

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 [].

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/vpnProvider#method-destroyConfig.
sourceraw docstring

destroy-config*cljs

(destroy-config* config id)
source

gen-callclj

source

gen-wrapclj/smacro

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

notify-connection-state-changedclj/smacro

(notify-connection-state-changed state)

Notifies the VPN session state to the platform. This will succeed only when the VPN session is owned by the extension.

|state| - The VPN session state of the VPN client.

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 [].

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/vpnProvider#method-notifyConnectionStateChanged.

Notifies the VPN session state to the platform. This will succeed only when the VPN session is owned by the extension.

  |state| - The VPN session state of the VPN client.

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 [].

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/vpnProvider#method-notifyConnectionStateChanged.
sourceraw docstring

notify-connection-state-changed*cljs

(notify-connection-state-changed* config state)
source

on-config-created*cljs

(on-config-created* config channel & args)
source

on-config-removed*cljs

(on-config-removed* config channel & args)
source

on-packet-received*cljs

(on-packet-received* config channel & args)
source

on-platform-message*cljs

(on-platform-message* config channel & args)
source

on-ui-event*cljs

(on-ui-event* config channel & args)
source

send-packetclj/smacro

(send-packet data)

Sends an IP packet through the tunnel created for the VPN session. This will succeed only when the VPN session is owned by the extension.

|data| - The IP packet to be sent to the platform.

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 [].

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/vpnProvider#method-sendPacket.

Sends an IP packet through the tunnel created for the VPN session. This will succeed only when the VPN session is owned by
the extension.

  |data| - The IP packet to be sent to the platform.

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 [].

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/vpnProvider#method-sendPacket.
sourceraw docstring

send-packet*cljs

(send-packet* config data)
source

set-parametersclj/smacro

(set-parameters parameters)

Sets the parameters for the VPN session. This should be called immediately after 'connected' is received from the platform. This will succeed only when the VPN session is owned by the extension.

|parameters| - The parameters for the VPN session.

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 [].

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/vpnProvider#method-setParameters.

Sets the parameters for the VPN session. This should be called immediately after 'connected' is received from the platform.
This will succeed only when the VPN session is owned by the extension.

  |parameters| - The parameters for the VPN session.

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 [].

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/vpnProvider#method-setParameters.
sourceraw docstring

set-parameters*cljs

(set-parameters* config parameters)
source

tap-all-eventsclj/smacro

(tap-all-events chan)

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

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

tap-on-config-created-eventsclj/smacro

(tap-on-config-created-events channel & args)

Triggered when a configuration is created by the platform for the extension.

Events will be put on the |channel| with signature [::on-config-created [id name data]] where:

|id| - ID of the configuration created. |name| - Name of the configuration created. |data| - Configuration data provided by the administrator.

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

https://developer.chrome.com/extensions/vpnProvider#event-onConfigCreated.

Triggered when a configuration is created by the platform for the extension.

Events will be put on the |channel| with signature [::on-config-created [id name data]] where:

  |id| - ID of the configuration created.
  |name| - Name of the configuration created.
  |data| - Configuration data provided by the administrator.

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

https://developer.chrome.com/extensions/vpnProvider#event-onConfigCreated.
sourceraw docstring

tap-on-config-removed-eventsclj/smacro

(tap-on-config-removed-events channel & args)

Triggered when a configuration created by the extension is removed by the platform.

Events will be put on the |channel| with signature [::on-config-removed [id]] where:

|id| - ID of the removed configuration.

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

https://developer.chrome.com/extensions/vpnProvider#event-onConfigRemoved.

Triggered when a configuration created by the extension is removed by the platform.

Events will be put on the |channel| with signature [::on-config-removed [id]] where:

  |id| - ID of the removed configuration.

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

https://developer.chrome.com/extensions/vpnProvider#event-onConfigRemoved.
sourceraw docstring

tap-on-packet-received-eventsclj/smacro

(tap-on-packet-received-events channel & args)

Triggered when an IP packet is received via the tunnel for the VPN session owned by the extension.

Events will be put on the |channel| with signature [::on-packet-received [data]] where:

|data| - The IP packet received from the platform.

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

https://developer.chrome.com/extensions/vpnProvider#event-onPacketReceived.

Triggered when an IP packet is received via the tunnel for the VPN session owned by the extension.

Events will be put on the |channel| with signature [::on-packet-received [data]] where:

  |data| - The IP packet received from the platform.

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

https://developer.chrome.com/extensions/vpnProvider#event-onPacketReceived.
sourceraw docstring

tap-on-platform-message-eventsclj/smacro

(tap-on-platform-message-events channel & args)

Triggered when a message is received from the platform for a VPN configuration owned by the extension.

Events will be put on the |channel| with signature [::on-platform-message [id message error]] where:

|id| - ID of the configuration the message is intended for. |message| - The message received from the platform. Note that new message types may be added in future Chrome versions to support new features. |error| - Error message when there is an error.

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

https://developer.chrome.com/extensions/vpnProvider#event-onPlatformMessage.

Triggered when a message is received from the platform for a VPN configuration owned by the extension.

Events will be put on the |channel| with signature [::on-platform-message [id message error]] where:

  |id| - ID of the configuration the message is intended for.
  |message| - The message received from the platform.  Note that new message types may be added in future Chrome versions
              to support new features.
  |error| - Error message when there is an error.

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

https://developer.chrome.com/extensions/vpnProvider#event-onPlatformMessage.
sourceraw docstring

tap-on-ui-event-eventsclj/smacro

(tap-on-ui-event-events channel & args)

Triggered when there is a UI event for the extension. UI events are signals from the platform that indicate to the app that a UI dialog needs to be shown to the user.

Events will be put on the |channel| with signature [::on-ui-event [event id]] where:

|event| - The UI event that is triggered. |id| - ID of the configuration for which the UI event was triggered.

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

https://developer.chrome.com/extensions/vpnProvider#event-onUIEvent.

Triggered when there is a UI event for the extension. UI events are signals from the platform that indicate to the app that
a UI dialog needs to be shown to the user.

Events will be put on the |channel| with signature [::on-ui-event [event id]] where:

  |event| - The UI event that is triggered.
  |id| - ID of the configuration for which the UI event was triggered.

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

https://developer.chrome.com/extensions/vpnProvider#event-onUIEvent.
sourceraw docstring

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

× close