@openfin/core 33.76.27 → 33.76.36
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/openfin-core-33.76.36.tgz +0 -0
- package/package.json +1 -1
- package/src/OpenFin.d.ts +27 -16
- package/src/api/application/Factory.d.ts +148 -100
- package/src/api/application/Factory.js +148 -100
- package/src/api/application/Instance.d.ts +477 -106
- package/src/api/application/Instance.js +474 -106
- package/src/api/application/index.d.ts +9 -0
- package/src/api/application/index.js +9 -0
- package/src/api/base.d.ts +69 -0
- package/src/api/base.js +69 -0
- package/src/api/clipboard/index.d.ts +111 -31
- package/src/api/clipboard/index.js +111 -31
- package/src/api/events/application.d.ts +12 -0
- package/src/api/events/application.js +12 -0
- package/src/api/events/channel.d.ts +5 -0
- package/src/api/events/channel.js +5 -0
- package/src/api/events/externalApplication.d.ts +5 -0
- package/src/api/events/externalApplication.js +5 -0
- package/src/api/events/frame.d.ts +5 -0
- package/src/api/events/globalHotkey.d.ts +5 -0
- package/src/api/events/platform.d.ts +9 -1
- package/src/api/events/platform.js +8 -0
- package/src/api/events/system.d.ts +13 -0
- package/src/api/events/system.js +13 -0
- package/src/api/events/view.d.ts +19 -9
- package/src/api/events/view.js +10 -0
- package/src/api/events/webcontents.d.ts +21 -10
- package/src/api/events/webcontents.js +11 -0
- package/src/api/events/window.d.ts +70 -1
- package/src/api/events/window.js +10 -0
- package/src/api/external-application/Factory.d.ts +16 -9
- package/src/api/external-application/Factory.js +16 -9
- package/src/api/external-application/Instance.d.ts +40 -32
- package/src/api/external-application/Instance.js +40 -32
- package/src/api/external-application/index.d.ts +9 -0
- package/src/api/external-application/index.js +9 -0
- package/src/api/fin.d.ts +3 -0
- package/src/api/fin.js +3 -0
- package/src/api/frame/Factory.d.ts +30 -13
- package/src/api/frame/Factory.js +30 -13
- package/src/api/frame/Instance.d.ts +51 -38
- package/src/api/frame/Instance.js +51 -38
- package/src/api/frame/index.d.ts +11 -0
- package/src/api/frame/index.js +11 -0
- package/src/api/global-hotkey/index.d.ts +81 -13
- package/src/api/global-hotkey/index.js +81 -13
- package/src/api/interappbus/channel/channel.d.ts +257 -0
- package/src/api/interappbus/channel/channel.js +257 -0
- package/src/api/interappbus/channel/channels-docs.d.ts +59 -57
- package/src/api/interappbus/channel/channels-docs.js +71 -68
- package/src/api/interappbus/channel/client.d.ts +93 -0
- package/src/api/interappbus/channel/client.js +93 -1
- package/src/api/interappbus/channel/index.d.ts +164 -0
- package/src/api/interappbus/channel/index.js +165 -1
- package/src/api/interappbus/channel/provider.d.ts +172 -0
- package/src/api/interappbus/channel/provider.js +172 -0
- package/src/api/interappbus/index.d.ts +55 -20
- package/src/api/interappbus/index.js +55 -20
- package/src/api/interop/Factory.d.ts +30 -10
- package/src/api/interop/Factory.js +30 -10
- package/src/api/interop/InteropBroker.d.ts +298 -70
- package/src/api/interop/InteropBroker.js +298 -70
- package/src/api/interop/InteropClient.d.ts +286 -62
- package/src/api/interop/InteropClient.js +286 -62
- package/src/api/interop/SessionContextGroupClient.d.ts +2 -2
- package/src/api/interop/SessionContextGroupClient.js +2 -2
- package/src/api/interop/fdc3/documentationStub.d.ts +14 -0
- package/src/api/interop/fdc3/documentationStub.js +17 -0
- package/src/api/interop/fdc3/fdc3-1.2.d.ts +31 -34
- package/src/api/interop/fdc3/fdc3-1.2.js +31 -34
- package/src/api/interop/fdc3/fdc3-2.0.d.ts +48 -51
- package/src/api/interop/fdc3/fdc3-2.0.js +48 -51
- package/src/api/interop/index.d.ts +8 -0
- package/src/api/interop/index.js +8 -0
- package/src/api/platform/Factory.d.ts +121 -65
- package/src/api/platform/Factory.js +122 -66
- package/src/api/platform/Instance.d.ts +551 -48
- package/src/api/platform/Instance.js +551 -49
- package/src/api/platform/index.d.ts +9 -0
- package/src/api/platform/index.js +9 -0
- package/src/api/platform/layout/Factory.d.ts +53 -76
- package/src/api/platform/layout/Factory.js +53 -76
- package/src/api/platform/layout/Instance.d.ts +158 -23
- package/src/api/platform/layout/Instance.js +118 -20
- package/src/api/platform/layout/entities/layout-entities.d.ts +222 -30
- package/src/api/platform/layout/entities/layout-entities.js +222 -30
- package/src/api/platform/layout/index.d.ts +9 -0
- package/src/api/platform/layout/index.js +9 -0
- package/src/api/platform/provider.d.ts +398 -51
- package/src/api/snapshot-source/Factory.d.ts +33 -18
- package/src/api/snapshot-source/Factory.js +33 -18
- package/src/api/snapshot-source/Instance.d.ts +30 -8
- package/src/api/snapshot-source/Instance.js +30 -8
- package/src/api/snapshot-source/index.d.ts +9 -0
- package/src/api/snapshot-source/index.js +9 -0
- package/src/api/system/index.d.ts +1137 -186
- package/src/api/system/index.js +1142 -186
- package/src/api/view/Factory.d.ts +54 -16
- package/src/api/view/Factory.js +54 -16
- package/src/api/view/Instance.d.ts +330 -216
- package/src/api/view/Instance.js +331 -217
- package/src/api/view/index.d.ts +9 -0
- package/src/api/view/index.js +9 -0
- package/src/api/webcontents/main.d.ts +890 -0
- package/src/api/webcontents/main.js +890 -0
- package/src/api/window/Factory.d.ts +67 -16
- package/src/api/window/Factory.js +67 -16
- package/src/api/window/Instance.d.ts +824 -316
- package/src/api/window/Instance.js +822 -320
- package/src/api/window/index.d.ts +11 -0
- package/src/api/window/index.js +11 -0
- package/src/namespaces.d.ts +1 -0
- package/src/namespaces.js +3 -1
- package/src/shapes/protocol.d.ts +4 -0
- package/openfin-core-33.76.27.tgz +0 -0
|
@@ -52,11 +52,8 @@ import { Base } from '../../base';
|
|
|
52
52
|
* @property { string } [providerVersion] The provider runtime version
|
|
53
53
|
*/
|
|
54
54
|
/**
|
|
55
|
-
* @class
|
|
56
|
-
* @alias fdc3
|
|
57
55
|
* @version 1.2
|
|
58
|
-
*
|
|
59
|
-
* @desc The FDC3 Client Library provides a set APIs to be used for FDC3 compliance,
|
|
56
|
+
* The FDC3 Client Library provides a set APIs to be used for FDC3 compliance,
|
|
60
57
|
* while using our Interop API under the hood. In order to use this set of APIs
|
|
61
58
|
* you will need to set up your own {@link InteropBroker InteropBroker} or use a Platform application, which does the setup for you. Refer to our documentation on
|
|
62
59
|
* our {@link https://developers.openfin.co/of-docs/docs/enable-color-linking Interop API}.
|
|
@@ -92,24 +89,24 @@ import { Base } from '../../base';
|
|
|
92
89
|
export default class Fdc3Module extends Base implements FDC3v1.DesktopAgent {
|
|
93
90
|
/**
|
|
94
91
|
* Add a context handler for incoming context. If an entity is part of a context group, and then sets its context handler, it will receive all of its declared contexts. If you wish to listen for all incoming contexts, pass `null` for the contextType argument.
|
|
95
|
-
* @param
|
|
96
|
-
* @param
|
|
97
|
-
*
|
|
92
|
+
* @param contextType - The type of context you wish to handle.
|
|
93
|
+
* @param handler - Handler for incoming context.
|
|
94
|
+
*
|
|
98
95
|
* @tutorial fdc3.addContextListener
|
|
99
96
|
* @static
|
|
100
97
|
*/
|
|
101
98
|
addContextListener(contextType: string | null, handler: FDC3v1.ContextHandler): FDC3v1.Listener & Promise<FDC3v1.Listener>;
|
|
102
99
|
/**
|
|
103
100
|
* Broadcasts a context for the channel of the current entity.
|
|
104
|
-
* @param
|
|
105
|
-
*
|
|
101
|
+
* @param context - New context to set.
|
|
102
|
+
*
|
|
106
103
|
* @tutorial fdc3.broadcast
|
|
107
104
|
* @static
|
|
108
105
|
*/
|
|
109
106
|
broadcast(context: FDC3v1.Context): Promise<void>;
|
|
110
107
|
/**
|
|
111
108
|
* Returns the Interop-Broker-defined context groups available for an entity to join.
|
|
112
|
-
*
|
|
109
|
+
*
|
|
113
110
|
* @tutorial fdc3.getSystemChannels
|
|
114
111
|
* @static
|
|
115
112
|
*/
|
|
@@ -120,8 +117,8 @@ export default class Fdc3Module extends Base implements FDC3v1.DesktopAgent {
|
|
|
120
117
|
* Because multiple Channel connections/Interop Clients can potentially exist at a `uuid`/`name` combo, we currently join all Channel connections/Interop Clients at the given identity to the context group.
|
|
121
118
|
* If an `endpointId` is provided (which is unlikely, unless the call is coming from an external adapter), then we only join that single connection to the context group.
|
|
122
119
|
* For all intents and purposes, there will only be 1 connection present in Platform and Browser implementations, so this point is more-or-less moot.
|
|
123
|
-
* @param
|
|
124
|
-
*
|
|
120
|
+
* @param channelId - Id of the context group.
|
|
121
|
+
*
|
|
125
122
|
* @tutorial fdc3.joinChannel
|
|
126
123
|
* @static
|
|
127
124
|
*/
|
|
@@ -129,77 +126,77 @@ export default class Fdc3Module extends Base implements FDC3v1.DesktopAgent {
|
|
|
129
126
|
/**
|
|
130
127
|
* Removes the specified target from a context group.
|
|
131
128
|
* If no target is specified, it removes the sender from their context group.
|
|
132
|
-
*
|
|
129
|
+
*
|
|
133
130
|
* @tutorial fdc3.leaveCurrentChannel
|
|
134
131
|
* @static
|
|
135
132
|
*/
|
|
136
133
|
leaveCurrentChannel(): Promise<void>;
|
|
137
134
|
/**
|
|
138
135
|
* Adds a listener for incoming Intents.
|
|
139
|
-
* @param
|
|
140
|
-
* @param
|
|
141
|
-
*
|
|
136
|
+
* @param intent - Name of the Intent
|
|
137
|
+
* @param handler - Handler for incoming Intent
|
|
138
|
+
*
|
|
142
139
|
* @tutorial fdc3.addIntentListener
|
|
143
140
|
* @static
|
|
144
141
|
*/
|
|
145
142
|
addIntentListener(intent: string, handler: FDC3v1.ContextHandler): FDC3v1.Listener & Promise<FDC3v1.Listener>;
|
|
146
143
|
/**
|
|
147
144
|
* Raises a specific intent.
|
|
148
|
-
* @param
|
|
149
|
-
* @param
|
|
150
|
-
* @param
|
|
151
|
-
*
|
|
145
|
+
* @param intent Name of the Intent.
|
|
146
|
+
* @param context Context associated with the Intent.
|
|
147
|
+
* @param app App that will resolve the Intent. This is added as metadata to the Intent. Can be accessed by the app provider in {@link InteropBroker#handleFiredIntent InteropBroker.handleFiredIntent}.
|
|
148
|
+
*
|
|
152
149
|
* @tutorial fdc3.raiseIntent
|
|
153
150
|
* @static
|
|
154
151
|
*/
|
|
155
152
|
raiseIntent(intent: string, context: FDC3v1.Context, app?: FDC3v1.TargetApp): Promise<FDC3v1.IntentResolution>;
|
|
156
153
|
/**
|
|
157
154
|
* Returns the Channel that the entity is subscribed to. Returns null if not joined to a channel.
|
|
158
|
-
*
|
|
155
|
+
*
|
|
159
156
|
* @tutorial fdc3.getCurrentChannel
|
|
160
157
|
*/
|
|
161
158
|
getCurrentChannel(): Promise<FDC3v1.Channel | null>;
|
|
162
159
|
/**
|
|
163
160
|
* Find out more information about a particular intent by passing its name, and optionally its context.
|
|
164
|
-
* @param
|
|
165
|
-
* @param
|
|
166
|
-
*
|
|
161
|
+
* @param intent Name of the Intent
|
|
162
|
+
* @param context
|
|
163
|
+
*
|
|
167
164
|
* @tutorial fdc3.findIntent
|
|
168
165
|
*/
|
|
169
166
|
findIntent(intent: string, context?: FDC3v1.Context): Promise<FDC3v1.AppIntent>;
|
|
170
167
|
/**
|
|
171
168
|
* Find all the available intents for a particular context.
|
|
172
|
-
* @param
|
|
173
|
-
*
|
|
169
|
+
* @param context
|
|
170
|
+
*
|
|
174
171
|
* @tutorial fdc3.findIntentsByContext
|
|
175
172
|
*/
|
|
176
173
|
findIntentsByContext(context: FDC3v1.Context): Promise<Array<FDC3v1.AppIntent>>;
|
|
177
174
|
/**
|
|
178
175
|
* Finds and raises an intent against a target app based purely on context data.
|
|
179
|
-
* @param
|
|
180
|
-
* @param
|
|
181
|
-
*
|
|
176
|
+
* @param context
|
|
177
|
+
* @param app
|
|
178
|
+
*
|
|
182
179
|
* @tutorial fdc3.raiseIntentForContext
|
|
183
180
|
*/
|
|
184
181
|
raiseIntentForContext(context: FDC3v1.Context, app?: FDC3v1.TargetApp): Promise<FDC3v1.IntentResolution>;
|
|
185
182
|
/**
|
|
186
183
|
* Returns a Channel object for the specified channel, creating it as an App Channel if it does not exist.
|
|
187
184
|
* @param channelId
|
|
188
|
-
*
|
|
185
|
+
*
|
|
189
186
|
* @tutorial fdc3.getOrCreateChannel
|
|
190
187
|
*/
|
|
191
188
|
getOrCreateChannel(channelId: string): Promise<FDC3v1.Channel>;
|
|
192
189
|
/**
|
|
193
190
|
* Returns metadata relating to the FDC3 object and its provider, including the supported version of the FDC3 specification and the name of the provider of the implementation.
|
|
194
|
-
*
|
|
191
|
+
*
|
|
195
192
|
* @tutorial fdc3.getInfo
|
|
196
193
|
*/
|
|
197
194
|
getInfo(): FDC3v1.ImplementationMetadata;
|
|
198
195
|
/**
|
|
199
196
|
* Launches an app with target information, which can either be a string or an AppMetadata object.
|
|
200
|
-
* @param
|
|
201
|
-
* @param
|
|
202
|
-
*
|
|
197
|
+
* @param app
|
|
198
|
+
* @param context
|
|
199
|
+
*
|
|
203
200
|
* @tutorial fdc3.open
|
|
204
201
|
*/
|
|
205
202
|
open(app: FDC3v1.TargetApp, context?: FDC3v1.Context): Promise<void>;
|
|
@@ -57,11 +57,8 @@ const lodash_1 = require("lodash");
|
|
|
57
57
|
* @property { string } [providerVersion] The provider runtime version
|
|
58
58
|
*/
|
|
59
59
|
/**
|
|
60
|
-
* @class
|
|
61
|
-
* @alias fdc3
|
|
62
60
|
* @version 1.2
|
|
63
|
-
*
|
|
64
|
-
* @desc The FDC3 Client Library provides a set APIs to be used for FDC3 compliance,
|
|
61
|
+
* The FDC3 Client Library provides a set APIs to be used for FDC3 compliance,
|
|
65
62
|
* while using our Interop API under the hood. In order to use this set of APIs
|
|
66
63
|
* you will need to set up your own {@link InteropBroker InteropBroker} or use a Platform application, which does the setup for you. Refer to our documentation on
|
|
67
64
|
* our {@link https://developers.openfin.co/of-docs/docs/enable-color-linking Interop API}.
|
|
@@ -97,9 +94,9 @@ const lodash_1 = require("lodash");
|
|
|
97
94
|
class Fdc3Module extends base_1.Base {
|
|
98
95
|
/**
|
|
99
96
|
* Add a context handler for incoming context. If an entity is part of a context group, and then sets its context handler, it will receive all of its declared contexts. If you wish to listen for all incoming contexts, pass `null` for the contextType argument.
|
|
100
|
-
* @param
|
|
101
|
-
* @param
|
|
102
|
-
*
|
|
97
|
+
* @param contextType - The type of context you wish to handle.
|
|
98
|
+
* @param handler - Handler for incoming context.
|
|
99
|
+
*
|
|
103
100
|
* @tutorial fdc3.addContextListener
|
|
104
101
|
* @static
|
|
105
102
|
*/
|
|
@@ -122,8 +119,8 @@ class Fdc3Module extends base_1.Base {
|
|
|
122
119
|
}
|
|
123
120
|
/**
|
|
124
121
|
* Broadcasts a context for the channel of the current entity.
|
|
125
|
-
* @param
|
|
126
|
-
*
|
|
122
|
+
* @param context - New context to set.
|
|
123
|
+
*
|
|
127
124
|
* @tutorial fdc3.broadcast
|
|
128
125
|
* @static
|
|
129
126
|
*/
|
|
@@ -135,7 +132,7 @@ class Fdc3Module extends base_1.Base {
|
|
|
135
132
|
}
|
|
136
133
|
/**
|
|
137
134
|
* Returns the Interop-Broker-defined context groups available for an entity to join.
|
|
138
|
-
*
|
|
135
|
+
*
|
|
139
136
|
* @tutorial fdc3.getSystemChannels
|
|
140
137
|
* @static
|
|
141
138
|
*/
|
|
@@ -156,8 +153,8 @@ class Fdc3Module extends base_1.Base {
|
|
|
156
153
|
* Because multiple Channel connections/Interop Clients can potentially exist at a `uuid`/`name` combo, we currently join all Channel connections/Interop Clients at the given identity to the context group.
|
|
157
154
|
* If an `endpointId` is provided (which is unlikely, unless the call is coming from an external adapter), then we only join that single connection to the context group.
|
|
158
155
|
* For all intents and purposes, there will only be 1 connection present in Platform and Browser implementations, so this point is more-or-less moot.
|
|
159
|
-
* @param
|
|
160
|
-
*
|
|
156
|
+
* @param channelId - Id of the context group.
|
|
157
|
+
*
|
|
161
158
|
* @tutorial fdc3.joinChannel
|
|
162
159
|
* @static
|
|
163
160
|
*/
|
|
@@ -184,7 +181,7 @@ class Fdc3Module extends base_1.Base {
|
|
|
184
181
|
/**
|
|
185
182
|
* Removes the specified target from a context group.
|
|
186
183
|
* If no target is specified, it removes the sender from their context group.
|
|
187
|
-
*
|
|
184
|
+
*
|
|
188
185
|
* @tutorial fdc3.leaveCurrentChannel
|
|
189
186
|
* @static
|
|
190
187
|
*/
|
|
@@ -196,9 +193,9 @@ class Fdc3Module extends base_1.Base {
|
|
|
196
193
|
}
|
|
197
194
|
/**
|
|
198
195
|
* Adds a listener for incoming Intents.
|
|
199
|
-
* @param
|
|
200
|
-
* @param
|
|
201
|
-
*
|
|
196
|
+
* @param intent - Name of the Intent
|
|
197
|
+
* @param handler - Handler for incoming Intent
|
|
198
|
+
*
|
|
202
199
|
* @tutorial fdc3.addIntentListener
|
|
203
200
|
* @static
|
|
204
201
|
*/
|
|
@@ -219,10 +216,10 @@ class Fdc3Module extends base_1.Base {
|
|
|
219
216
|
}
|
|
220
217
|
/**
|
|
221
218
|
* Raises a specific intent.
|
|
222
|
-
* @param
|
|
223
|
-
* @param
|
|
224
|
-
* @param
|
|
225
|
-
*
|
|
219
|
+
* @param intent Name of the Intent.
|
|
220
|
+
* @param context Context associated with the Intent.
|
|
221
|
+
* @param app App that will resolve the Intent. This is added as metadata to the Intent. Can be accessed by the app provider in {@link InteropBroker#handleFiredIntent InteropBroker.handleFiredIntent}.
|
|
222
|
+
*
|
|
226
223
|
* @tutorial fdc3.raiseIntent
|
|
227
224
|
* @static
|
|
228
225
|
*/
|
|
@@ -243,7 +240,7 @@ class Fdc3Module extends base_1.Base {
|
|
|
243
240
|
}
|
|
244
241
|
/**
|
|
245
242
|
* Returns the Channel that the entity is subscribed to. Returns null if not joined to a channel.
|
|
246
|
-
*
|
|
243
|
+
*
|
|
247
244
|
* @tutorial fdc3.getCurrentChannel
|
|
248
245
|
*/
|
|
249
246
|
async getCurrentChannel() {
|
|
@@ -258,9 +255,9 @@ class Fdc3Module extends base_1.Base {
|
|
|
258
255
|
}
|
|
259
256
|
/**
|
|
260
257
|
* Find out more information about a particular intent by passing its name, and optionally its context.
|
|
261
|
-
* @param
|
|
262
|
-
* @param
|
|
263
|
-
*
|
|
258
|
+
* @param intent Name of the Intent
|
|
259
|
+
* @param context
|
|
260
|
+
*
|
|
264
261
|
* @tutorial fdc3.findIntent
|
|
265
262
|
*/
|
|
266
263
|
async findIntent(intent, context) {
|
|
@@ -277,8 +274,8 @@ class Fdc3Module extends base_1.Base {
|
|
|
277
274
|
}
|
|
278
275
|
/**
|
|
279
276
|
* Find all the available intents for a particular context.
|
|
280
|
-
* @param
|
|
281
|
-
*
|
|
277
|
+
* @param context
|
|
278
|
+
*
|
|
282
279
|
* @tutorial fdc3.findIntentsByContext
|
|
283
280
|
*/
|
|
284
281
|
async findIntentsByContext(context) {
|
|
@@ -295,9 +292,9 @@ class Fdc3Module extends base_1.Base {
|
|
|
295
292
|
}
|
|
296
293
|
/**
|
|
297
294
|
* Finds and raises an intent against a target app based purely on context data.
|
|
298
|
-
* @param
|
|
299
|
-
* @param
|
|
300
|
-
*
|
|
295
|
+
* @param context
|
|
296
|
+
* @param app
|
|
297
|
+
*
|
|
301
298
|
* @tutorial fdc3.raiseIntentForContext
|
|
302
299
|
*/
|
|
303
300
|
async raiseIntentForContext(context, app) {
|
|
@@ -315,7 +312,7 @@ class Fdc3Module extends base_1.Base {
|
|
|
315
312
|
/**
|
|
316
313
|
* Returns a Channel object for the specified channel, creating it as an App Channel if it does not exist.
|
|
317
314
|
* @param channelId
|
|
318
|
-
*
|
|
315
|
+
*
|
|
319
316
|
* @tutorial fdc3.getOrCreateChannel
|
|
320
317
|
*/
|
|
321
318
|
async getOrCreateChannel(channelId) {
|
|
@@ -338,7 +335,7 @@ class Fdc3Module extends base_1.Base {
|
|
|
338
335
|
}
|
|
339
336
|
/**
|
|
340
337
|
* Returns metadata relating to the FDC3 object and its provider, including the supported version of the FDC3 specification and the name of the provider of the implementation.
|
|
341
|
-
*
|
|
338
|
+
*
|
|
342
339
|
* @tutorial fdc3.getInfo
|
|
343
340
|
*/
|
|
344
341
|
getInfo() {
|
|
@@ -357,9 +354,9 @@ class Fdc3Module extends base_1.Base {
|
|
|
357
354
|
}
|
|
358
355
|
/**
|
|
359
356
|
* Launches an app with target information, which can either be a string or an AppMetadata object.
|
|
360
|
-
* @param
|
|
361
|
-
* @param
|
|
362
|
-
*
|
|
357
|
+
* @param app
|
|
358
|
+
* @param context
|
|
359
|
+
*
|
|
363
360
|
* @tutorial fdc3.open
|
|
364
361
|
*/
|
|
365
362
|
async open(app, context) {
|
|
@@ -66,16 +66,16 @@ import { Transport } from '../../../transport/transport';
|
|
|
66
66
|
/**
|
|
67
67
|
* @callback ContextHandler
|
|
68
68
|
* @variation 2
|
|
69
|
-
* @param
|
|
70
|
-
* @param
|
|
71
|
-
*
|
|
69
|
+
* @param context
|
|
70
|
+
* @param contextMetadata
|
|
71
|
+
*
|
|
72
72
|
*/
|
|
73
73
|
/**
|
|
74
74
|
* @callback IntentHandler
|
|
75
75
|
* @variation 2
|
|
76
|
-
* @param
|
|
77
|
-
* @param
|
|
78
|
-
*
|
|
76
|
+
* @param context
|
|
77
|
+
* @param contextMetadata
|
|
78
|
+
*
|
|
79
79
|
*/
|
|
80
80
|
/**
|
|
81
81
|
* @typedef { object } IntentMetadata
|
|
@@ -93,7 +93,7 @@ import { Transport } from '../../../transport/transport';
|
|
|
93
93
|
/**
|
|
94
94
|
* @name getResult
|
|
95
95
|
* @function
|
|
96
|
-
*
|
|
96
|
+
*
|
|
97
97
|
*/
|
|
98
98
|
/**
|
|
99
99
|
* @typedef { object } IntentResolution
|
|
@@ -119,11 +119,8 @@ import { Transport } from '../../../transport/transport';
|
|
|
119
119
|
* @property { function } disconnect
|
|
120
120
|
*/
|
|
121
121
|
/**
|
|
122
|
-
* @class
|
|
123
|
-
* @alias fdc3v2
|
|
124
122
|
* @version 2.0
|
|
125
|
-
*
|
|
126
|
-
* @desc The FDC3 Client Library provides a set APIs to be used for FDC3 compliance,
|
|
123
|
+
* The FDC3 Client Library provides a set APIs to be used for FDC3 compliance,
|
|
127
124
|
* while using our Interop API under the hood. In order to use this set of APIs
|
|
128
125
|
* you will need to set up your own {@link InteropBroker InteropBroker} or use a Platform application, which does the setup for you. Refer to our documentation on
|
|
129
126
|
* our {@link https://developers.openfin.co/of-docs/docs/enable-context-sharing Interop API}.
|
|
@@ -161,140 +158,140 @@ export default class Fdc3Module2 extends Base implements FDC3v2.DesktopAgent {
|
|
|
161
158
|
constructor(wire: Transport);
|
|
162
159
|
/**
|
|
163
160
|
* Launches an app, specified via an AppIdentifier object.
|
|
164
|
-
* @param
|
|
165
|
-
* @param
|
|
166
|
-
*
|
|
161
|
+
* @param app
|
|
162
|
+
* @param context
|
|
163
|
+
*
|
|
167
164
|
* @tutorial fdc3.open
|
|
168
165
|
*/
|
|
169
166
|
open(app: FDC3v2.AppIdentifier | FDC3v1.TargetApp, context?: FDC3v2.Context): Promise<FDC3v2.AppIdentifier>;
|
|
170
167
|
/**
|
|
171
168
|
* Find all the available instances for a particular application.
|
|
172
|
-
* @param
|
|
173
|
-
*
|
|
169
|
+
* @param app
|
|
170
|
+
*
|
|
174
171
|
* @tutorial fdc3v2.findInstances
|
|
175
172
|
*/
|
|
176
173
|
findInstances(app: FDC3v2.AppIdentifier): Promise<Array<FDC3v2.AppIdentifier>>;
|
|
177
174
|
/**
|
|
178
175
|
* Retrieves the AppMetadata for an AppIdentifier, which provides additional metadata (such as icons, a title and description) from the App Directory record for the application, that may be used for display purposes.
|
|
179
|
-
* @param
|
|
180
|
-
*
|
|
176
|
+
* @param app
|
|
177
|
+
*
|
|
181
178
|
* @tutorial fdc3v2.getAppMetadata
|
|
182
179
|
*/
|
|
183
180
|
getAppMetadata(app: FDC3v2.AppIdentifier): Promise<FDC3v2.AppMetadata>;
|
|
184
181
|
/**
|
|
185
182
|
* Broadcasts a context for the channel of the current entity.
|
|
186
|
-
* @param
|
|
187
|
-
*
|
|
183
|
+
* @param context - New context to set.
|
|
184
|
+
*
|
|
188
185
|
* @tutorial fdc3.broadcast
|
|
189
186
|
*/
|
|
190
187
|
broadcast(context: FDC3v2.Context): Promise<void>;
|
|
191
188
|
/**
|
|
192
189
|
* Add a context handler for incoming context. If an entity is part of a context group, and then sets its context handler, it will receive all of its declared contexts. If you wish to listen for all incoming contexts, pass `null` for the contextType argument.
|
|
193
|
-
* @param
|
|
194
|
-
* @param
|
|
195
|
-
*
|
|
190
|
+
* @param contextType
|
|
191
|
+
* @param handler
|
|
192
|
+
*
|
|
196
193
|
* @tutorial fdc3.addContextListener
|
|
197
194
|
*/
|
|
198
195
|
addContextListener(contextType: string | null, handler: FDC3v2.ContextHandler): Promise<FDC3v2.Listener>;
|
|
199
196
|
/**
|
|
200
197
|
* Find out more information about a particular intent by passing its name, and optionally its context and resultType.
|
|
201
|
-
* @param
|
|
202
|
-
* @param
|
|
203
|
-
* @param
|
|
204
|
-
*
|
|
198
|
+
* @param intent Name of the Intent
|
|
199
|
+
* @param context Context
|
|
200
|
+
* @param resultType The type of result returned for any intent specified during resolution.
|
|
201
|
+
*
|
|
205
202
|
* @tutorial fdc3.findIntent
|
|
206
203
|
*/
|
|
207
204
|
findIntent(intent: string, context?: FDC3v2.Context, resultType?: string): Promise<FDC3v2.AppIntent>;
|
|
208
205
|
/**
|
|
209
206
|
* Find all the available intents for a particular context.
|
|
210
|
-
* @param
|
|
211
|
-
* @param
|
|
212
|
-
*
|
|
207
|
+
* @param context
|
|
208
|
+
* @param resultType The type of result returned for any intent specified during resolution.
|
|
209
|
+
*
|
|
213
210
|
* @tutorial fdc3v2.findIntentsByContext
|
|
214
211
|
*/
|
|
215
212
|
findIntentsByContext(context: FDC3v2.Context, resultType?: string): Promise<Array<FDC3v2.AppIntent>>;
|
|
216
213
|
/**
|
|
217
214
|
* Raises a specific intent for resolution against apps registered with the desktop agent.
|
|
218
|
-
* @param
|
|
219
|
-
* @param
|
|
220
|
-
* @param
|
|
221
|
-
*
|
|
215
|
+
* @param intent Name of the Intent
|
|
216
|
+
* @param context Context associated with the Intent
|
|
217
|
+
* @param app
|
|
218
|
+
*
|
|
222
219
|
* @tutorial fdc3v2.raiseIntent
|
|
223
220
|
*/
|
|
224
221
|
raiseIntent(intent: string, context: FDC3v2.Context, app?: FDC3v2.AppIdentifier | FDC3v1.TargetApp): Promise<FDC3v2.IntentResolution>;
|
|
225
222
|
/**
|
|
226
223
|
* Finds and raises an intent against apps registered with the desktop agent based purely on the type of the context data.
|
|
227
|
-
* @param
|
|
228
|
-
* @param
|
|
229
|
-
*
|
|
224
|
+
* @param context Context associated with the Intent
|
|
225
|
+
* @param app
|
|
226
|
+
*
|
|
230
227
|
* @tutorial fdc3v2.raiseIntentForContext
|
|
231
228
|
*/
|
|
232
229
|
raiseIntentForContext(context: FDC3v2.Context, app?: FDC3v2.AppIdentifier | FDC3v1.TargetApp): Promise<FDC3v2.IntentResolution>;
|
|
233
230
|
/**
|
|
234
231
|
* Adds a listener for incoming intents.
|
|
235
|
-
* @param
|
|
236
|
-
* @param
|
|
237
|
-
*
|
|
232
|
+
* @param intent Name of the Intent
|
|
233
|
+
* @param handler A callback that handles a context event and may return a promise of a Context or Channel object to be returned to the application that raised the intent.
|
|
234
|
+
*
|
|
238
235
|
* @tutorial fdc3.addIntentListener
|
|
239
236
|
*/
|
|
240
237
|
addIntentListener(intent: string, handler: FDC3v2.IntentHandler): Promise<FDC3v1.Listener>;
|
|
241
238
|
/**
|
|
242
239
|
* Returns a Channel object for the specified channel, creating it as an App Channel if it does not exist.
|
|
243
240
|
* @param channelId
|
|
244
|
-
*
|
|
241
|
+
*
|
|
245
242
|
* @tutorial fdc3.getOrCreateChannel
|
|
246
243
|
*/
|
|
247
244
|
getOrCreateChannel(channelId: string): Promise<FDC3v2.Channel>;
|
|
248
245
|
/**
|
|
249
246
|
* Returns a Channel with an auto-generated identity that is intended for private communication between applications. Primarily used to create channels that will be returned to other applications via an IntentResolution for a raised intent.
|
|
250
|
-
*
|
|
247
|
+
*
|
|
251
248
|
* @tutorial fdc3v2.createPrivateChannel
|
|
252
249
|
*/
|
|
253
250
|
createPrivateChannel(): Promise<FDC3v2.PrivateChannel>;
|
|
254
251
|
/**
|
|
255
252
|
* Retrieves a list of the User Channels available for the app to join.
|
|
256
|
-
*
|
|
253
|
+
*
|
|
257
254
|
* @tutorial fdc3v2.getUserChannels
|
|
258
255
|
*/
|
|
259
256
|
getUserChannels(): Promise<Array<FDC3v1.SystemChannel>>;
|
|
260
257
|
/**
|
|
261
258
|
* Retrieves a list of the User Channels available for the app to join.
|
|
262
|
-
*
|
|
259
|
+
*
|
|
263
260
|
* @deprecated Please use {@link fdc3.getUserChannels fdc3.getUserChannels} instead
|
|
264
261
|
* @tutorial fdc3.getSystemChannels
|
|
265
262
|
*/
|
|
266
263
|
getSystemChannels(): Promise<Array<FDC3v1.SystemChannel>>;
|
|
267
264
|
/**
|
|
268
265
|
* Join an app to a specified User channel.
|
|
269
|
-
* @param
|
|
270
|
-
*
|
|
266
|
+
* @param channelId Channel name
|
|
267
|
+
*
|
|
271
268
|
* @tutorial fdc3v2.joinUserChannel
|
|
272
269
|
*/
|
|
273
270
|
joinUserChannel(channelId: string): Promise<void>;
|
|
274
271
|
/**
|
|
275
272
|
* Join an app to a specified User channel.
|
|
276
|
-
* @param
|
|
273
|
+
* @param channelId Channel name
|
|
277
274
|
* @deprecated Please use {@link fdc3.joinUserChannel fdc3.joinUserChannel} instead
|
|
278
|
-
*
|
|
275
|
+
*
|
|
279
276
|
* @tutorial fdc3.joinChannel
|
|
280
277
|
*/
|
|
281
278
|
joinChannel(channelId: string): Promise<void>;
|
|
282
279
|
/**
|
|
283
280
|
* Returns the Channel object for the current User channel membership
|
|
284
|
-
*
|
|
281
|
+
*
|
|
285
282
|
* @tutorial fdc3.getCurrentChannel
|
|
286
283
|
*/
|
|
287
284
|
getCurrentChannel(): Promise<FDC3v2.Channel | null>;
|
|
288
285
|
/**
|
|
289
286
|
* Removes the app from any User channel membership.
|
|
290
|
-
*
|
|
287
|
+
*
|
|
291
288
|
* @tutorial fdc3.leaveCurrentChannel
|
|
292
289
|
*/
|
|
293
290
|
leaveCurrentChannel(): Promise<void>;
|
|
294
291
|
/**
|
|
295
292
|
* Retrieves information about the FDC3 implementation, including the supported version of the FDC3 specification, the name of the provider of the implementation, its own version number, details of whether optional API features are implemented and the metadata of the calling application according to the desktop agent.
|
|
296
293
|
* fdc3HandleGetInfo must be overridden in the InteropBroker so that the ImplementationMetadata will have the appMetadata info.
|
|
297
|
-
*
|
|
294
|
+
*
|
|
298
295
|
* @tutorial fdc3v2.getInfo
|
|
299
296
|
*/
|
|
300
297
|
getInfo(): Promise<FDC3v2.ImplementationMetadata>;
|