@openfin/core 33.76.36 → 33.77.1

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.
Files changed (271) hide show
  1. package/OpenFin.d.ts +1 -1
  2. package/README.md +29 -4
  3. package/fin.d.ts +2 -2
  4. package/{src → out}/GlobalOpenFin.d.ts +1 -1
  5. package/out/mock-alpha.d.ts +16112 -0
  6. package/out/mock-beta.d.ts +16112 -0
  7. package/out/mock-public.d.ts +16112 -0
  8. package/out/mock.d.ts +16797 -0
  9. package/out/mock.js +17111 -0
  10. package/package.json +30 -23
  11. package/LICENSE +0 -13
  12. package/NOTICE +0 -16
  13. package/openfin-core-33.76.36.tgz +0 -0
  14. package/src/OpenFin.d.ts +0 -3091
  15. package/src/OpenFin.js +0 -2
  16. package/src/api/api-exposer/api-consumer.d.ts +0 -28
  17. package/src/api/api-exposer/api-consumer.js +0 -28
  18. package/src/api/api-exposer/api-exposer.d.ts +0 -35
  19. package/src/api/api-exposer/api-exposer.js +0 -38
  20. package/src/api/api-exposer/decorators.d.ts +0 -10
  21. package/src/api/api-exposer/decorators.js +0 -18
  22. package/src/api/api-exposer/index.d.ts +0 -4
  23. package/src/api/api-exposer/index.js +0 -20
  24. package/src/api/api-exposer/strategies/index.d.ts +0 -1
  25. package/src/api/api-exposer/strategies/index.js +0 -17
  26. package/src/api/api-exposer/strategies/openfin-channels/channels-consumer.d.ts +0 -14
  27. package/src/api/api-exposer/strategies/openfin-channels/channels-consumer.js +0 -20
  28. package/src/api/api-exposer/strategies/openfin-channels/channels-exposer.d.ts +0 -20
  29. package/src/api/api-exposer/strategies/openfin-channels/channels-exposer.js +0 -23
  30. package/src/api/api-exposer/strategies/openfin-channels/index.d.ts +0 -2
  31. package/src/api/api-exposer/strategies/openfin-channels/index.js +0 -18
  32. package/src/api/application/Factory.d.ts +0 -196
  33. package/src/api/application/Factory.js +0 -278
  34. package/src/api/application/Instance.d.ts +0 -692
  35. package/src/api/application/Instance.js +0 -821
  36. package/src/api/application/index.d.ts +0 -12
  37. package/src/api/application/index.js +0 -28
  38. package/src/api/base.d.ts +0 -117
  39. package/src/api/base.js +0 -246
  40. package/src/api/clipboard/index.d.ts +0 -172
  41. package/src/api/clipboard/index.js +0 -200
  42. package/src/api/events/application.d.ts +0 -158
  43. package/src/api/events/application.js +0 -14
  44. package/src/api/events/base.d.ts +0 -42
  45. package/src/api/events/base.js +0 -2
  46. package/src/api/events/channel.d.ts +0 -35
  47. package/src/api/events/channel.js +0 -7
  48. package/src/api/events/emitterMap.d.ts +0 -11
  49. package/src/api/events/emitterMap.js +0 -35
  50. package/src/api/events/eventAggregator.d.ts +0 -5
  51. package/src/api/events/eventAggregator.js +0 -35
  52. package/src/api/events/externalApplication.d.ts +0 -24
  53. package/src/api/events/externalApplication.js +0 -7
  54. package/src/api/events/frame.d.ts +0 -35
  55. package/src/api/events/frame.js +0 -2
  56. package/src/api/events/globalHotkey.d.ts +0 -25
  57. package/src/api/events/globalHotkey.js +0 -2
  58. package/src/api/events/platform.d.ts +0 -34
  59. package/src/api/events/platform.js +0 -10
  60. package/src/api/events/system.d.ts +0 -126
  61. package/src/api/events/system.js +0 -15
  62. package/src/api/events/typedEventEmitter.d.ts +0 -20
  63. package/src/api/events/typedEventEmitter.js +0 -2
  64. package/src/api/events/view.d.ts +0 -92
  65. package/src/api/events/view.js +0 -12
  66. package/src/api/events/webcontents.d.ts +0 -277
  67. package/src/api/events/webcontents.js +0 -13
  68. package/src/api/events/window.d.ts +0 -421
  69. package/src/api/events/window.js +0 -12
  70. package/src/api/external-application/Factory.d.ts +0 -34
  71. package/src/api/external-application/Factory.js +0 -47
  72. package/src/api/external-application/Instance.d.ts +0 -110
  73. package/src/api/external-application/Instance.js +0 -117
  74. package/src/api/external-application/index.d.ts +0 -12
  75. package/src/api/external-application/index.js +0 -28
  76. package/src/api/fin.d.ts +0 -54
  77. package/src/api/fin.js +0 -45
  78. package/src/api/frame/Factory.d.ts +0 -54
  79. package/src/api/frame/Factory.js +0 -86
  80. package/src/api/frame/Instance.d.ts +0 -136
  81. package/src/api/frame/Instance.js +0 -143
  82. package/src/api/frame/index.d.ts +0 -14
  83. package/src/api/frame/index.js +0 -30
  84. package/src/api/global-hotkey/index.d.ts +0 -106
  85. package/src/api/global-hotkey/index.js +0 -132
  86. package/src/api/interappbus/channel/channel.d.ts +0 -285
  87. package/src/api/interappbus/channel/channel.js +0 -334
  88. package/src/api/interappbus/channel/channels-docs.d.ts +0 -342
  89. package/src/api/interappbus/channel/channels-docs.js +0 -401
  90. package/src/api/interappbus/channel/client.d.ts +0 -117
  91. package/src/api/interappbus/channel/client.js +0 -181
  92. package/src/api/interappbus/channel/connection-manager.d.ts +0 -29
  93. package/src/api/interappbus/channel/connection-manager.js +0 -246
  94. package/src/api/interappbus/channel/index.d.ts +0 -189
  95. package/src/api/interappbus/channel/index.js +0 -333
  96. package/src/api/interappbus/channel/protocols/classic/message-receiver.d.ts +0 -13
  97. package/src/api/interappbus/channel/protocols/classic/message-receiver.js +0 -73
  98. package/src/api/interappbus/channel/protocols/classic/strategy.d.ts +0 -24
  99. package/src/api/interappbus/channel/protocols/classic/strategy.js +0 -101
  100. package/src/api/interappbus/channel/protocols/combined/strategy.d.ts +0 -20
  101. package/src/api/interappbus/channel/protocols/combined/strategy.js +0 -58
  102. package/src/api/interappbus/channel/protocols/index.d.ts +0 -47
  103. package/src/api/interappbus/channel/protocols/index.js +0 -2
  104. package/src/api/interappbus/channel/protocols/protocol-manager.d.ts +0 -10
  105. package/src/api/interappbus/channel/protocols/protocol-manager.js +0 -43
  106. package/src/api/interappbus/channel/protocols/rtc/endpoint.d.ts +0 -25
  107. package/src/api/interappbus/channel/protocols/rtc/endpoint.js +0 -141
  108. package/src/api/interappbus/channel/protocols/rtc/ice-manager.d.ts +0 -30
  109. package/src/api/interappbus/channel/protocols/rtc/ice-manager.js +0 -130
  110. package/src/api/interappbus/channel/protocols/rtc/strategy.d.ts +0 -24
  111. package/src/api/interappbus/channel/protocols/rtc/strategy.js +0 -85
  112. package/src/api/interappbus/channel/protocols/strategy-types.d.ts +0 -13
  113. package/src/api/interappbus/channel/protocols/strategy-types.js +0 -2
  114. package/src/api/interappbus/channel/protocols/strategy.d.ts +0 -17
  115. package/src/api/interappbus/channel/protocols/strategy.js +0 -2
  116. package/src/api/interappbus/channel/provider.d.ts +0 -206
  117. package/src/api/interappbus/channel/provider.js +0 -338
  118. package/src/api/interappbus/index.d.ts +0 -120
  119. package/src/api/interappbus/index.js +0 -210
  120. package/src/api/interop/Factory.d.ts +0 -57
  121. package/src/api/interop/Factory.js +0 -96
  122. package/src/api/interop/InteropBroker.d.ts +0 -665
  123. package/src/api/interop/InteropBroker.js +0 -1313
  124. package/src/api/interop/InteropClient.d.ts +0 -502
  125. package/src/api/interop/InteropClient.js +0 -683
  126. package/src/api/interop/SessionContextGroupBroker.d.ts +0 -27
  127. package/src/api/interop/SessionContextGroupBroker.js +0 -108
  128. package/src/api/interop/SessionContextGroupClient.d.ts +0 -21
  129. package/src/api/interop/SessionContextGroupClient.js +0 -86
  130. package/src/api/interop/fdc3/PrivateChannelClient.d.ts +0 -20
  131. package/src/api/interop/fdc3/PrivateChannelClient.js +0 -90
  132. package/src/api/interop/fdc3/PrivateChannelProvider.d.ts +0 -55
  133. package/src/api/interop/fdc3/PrivateChannelProvider.js +0 -276
  134. package/src/api/interop/fdc3/documentationStub.d.ts +0 -14
  135. package/src/api/interop/fdc3/documentationStub.js +0 -17
  136. package/src/api/interop/fdc3/fdc3-1.2.d.ts +0 -205
  137. package/src/api/interop/fdc3/fdc3-1.2.js +0 -435
  138. package/src/api/interop/fdc3/fdc3-2.0.d.ts +0 -298
  139. package/src/api/interop/fdc3/fdc3-2.0.js +0 -479
  140. package/src/api/interop/fdc3/fdc3.d.ts +0 -12
  141. package/src/api/interop/fdc3/fdc3.js +0 -35
  142. package/src/api/interop/fdc3/overrideCheck.d.ts +0 -4
  143. package/src/api/interop/fdc3/overrideCheck.js +0 -32
  144. package/src/api/interop/fdc3/shapes/fdc3v1.d.ts +0 -53
  145. package/src/api/interop/fdc3/shapes/fdc3v1.js +0 -4
  146. package/src/api/interop/fdc3/shapes/fdc3v2.d.ts +0 -75
  147. package/src/api/interop/fdc3/shapes/fdc3v2.js +0 -2
  148. package/src/api/interop/fdc3/utils.d.ts +0 -45
  149. package/src/api/interop/fdc3/utils.js +0 -239
  150. package/src/api/interop/fdc3/versions.d.ts +0 -1
  151. package/src/api/interop/fdc3/versions.js +0 -2
  152. package/src/api/interop/index.d.ts +0 -12
  153. package/src/api/interop/index.js +0 -28
  154. package/src/api/interop/utils.d.ts +0 -18
  155. package/src/api/interop/utils.js +0 -61
  156. package/src/api/me.d.ts +0 -40
  157. package/src/api/me.js +0 -134
  158. package/src/api/platform/Factory.d.ts +0 -171
  159. package/src/api/platform/Factory.js +0 -240
  160. package/src/api/platform/Instance.d.ts +0 -653
  161. package/src/api/platform/Instance.js +0 -834
  162. package/src/api/platform/common-utils.d.ts +0 -7
  163. package/src/api/platform/common-utils.js +0 -16
  164. package/src/api/platform/index.d.ts +0 -12
  165. package/src/api/platform/index.js +0 -28
  166. package/src/api/platform/layout/Factory.d.ts +0 -91
  167. package/src/api/platform/layout/Factory.js +0 -151
  168. package/src/api/platform/layout/Instance.d.ts +0 -192
  169. package/src/api/platform/layout/Instance.js +0 -224
  170. package/src/api/platform/layout/controllers/layout-content-cache.d.ts +0 -9
  171. package/src/api/platform/layout/controllers/layout-content-cache.js +0 -54
  172. package/src/api/platform/layout/controllers/layout-entities-controller.d.ts +0 -119
  173. package/src/api/platform/layout/controllers/layout-entities-controller.js +0 -287
  174. package/src/api/platform/layout/entities/layout-entities.d.ts +0 -427
  175. package/src/api/platform/layout/entities/layout-entities.js +0 -504
  176. package/src/api/platform/layout/entities/shapes.d.ts +0 -6
  177. package/src/api/platform/layout/entities/shapes.js +0 -2
  178. package/src/api/platform/layout/index.d.ts +0 -11
  179. package/src/api/platform/layout/index.js +0 -27
  180. package/src/api/platform/layout/layout.constants.d.ts +0 -1
  181. package/src/api/platform/layout/layout.constants.js +0 -4
  182. package/src/api/platform/layout/shapes.d.ts +0 -16
  183. package/src/api/platform/layout/shapes.js +0 -2
  184. package/src/api/platform/layout/utils/layout-traversal.d.ts +0 -4
  185. package/src/api/platform/layout/utils/layout-traversal.js +0 -65
  186. package/src/api/platform/provider.d.ts +0 -510
  187. package/src/api/platform/provider.js +0 -2
  188. package/src/api/snapshot-source/Factory.d.ts +0 -53
  189. package/src/api/snapshot-source/Factory.js +0 -81
  190. package/src/api/snapshot-source/Instance.d.ts +0 -53
  191. package/src/api/snapshot-source/Instance.js +0 -154
  192. package/src/api/snapshot-source/index.d.ts +0 -12
  193. package/src/api/snapshot-source/index.js +0 -28
  194. package/src/api/snapshot-source/utils.d.ts +0 -2
  195. package/src/api/snapshot-source/utils.js +0 -6
  196. package/src/api/system/index.d.ts +0 -1468
  197. package/src/api/system/index.js +0 -1851
  198. package/src/api/view/Factory.d.ts +0 -88
  199. package/src/api/view/Factory.js +0 -141
  200. package/src/api/view/Instance.d.ts +0 -601
  201. package/src/api/view/Instance.js +0 -671
  202. package/src/api/view/index.d.ts +0 -12
  203. package/src/api/view/index.js +0 -28
  204. package/src/api/webcontents/main.d.ts +0 -922
  205. package/src/api/webcontents/main.js +0 -1046
  206. package/src/api/window/Factory.d.ts +0 -96
  207. package/src/api/window/Factory.js +0 -142
  208. package/src/api/window/Instance.d.ts +0 -1598
  209. package/src/api/window/Instance.js +0 -1851
  210. package/src/api/window/index.d.ts +0 -14
  211. package/src/api/window/index.js +0 -30
  212. package/src/browser.d.ts +0 -10
  213. package/src/browser.js +0 -36
  214. package/src/environment/browser.d.ts +0 -29
  215. package/src/environment/browser.js +0 -60
  216. package/src/environment/environment.d.ts +0 -33
  217. package/src/environment/environment.js +0 -4
  218. package/src/environment/mockEnvironment.d.ts +0 -27
  219. package/src/environment/mockEnvironment.js +0 -61
  220. package/src/environment/node-env.d.ts +0 -29
  221. package/src/environment/node-env.js +0 -72
  222. package/src/fdc3.d.ts +0 -3
  223. package/src/fdc3.js +0 -9
  224. package/src/mock.d.ts +0 -3
  225. package/src/mock.js +0 -18
  226. package/src/namespaces.d.ts +0 -22
  227. package/src/namespaces.js +0 -26
  228. package/src/shapes/ERROR_BOX_TYPES.d.ts +0 -1
  229. package/src/shapes/ERROR_BOX_TYPES.js +0 -2
  230. package/src/shapes/WebOptions.d.ts +0 -13
  231. package/src/shapes/WebOptions.js +0 -2
  232. package/src/shapes/WindowOptions.d.ts +0 -43
  233. package/src/shapes/WindowOptions.js +0 -2
  234. package/src/shapes/protocol.d.ts +0 -204
  235. package/src/shapes/protocol.js +0 -2
  236. package/src/transport/mockWire.d.ts +0 -11
  237. package/src/transport/mockWire.js +0 -26
  238. package/src/transport/transport-errors.d.ts +0 -31
  239. package/src/transport/transport-errors.js +0 -79
  240. package/src/transport/transport.d.ts +0 -73
  241. package/src/transport/transport.js +0 -219
  242. package/src/transport/wire.d.ts +0 -77
  243. package/src/transport/wire.js +0 -36
  244. package/src/util/asyncFilter.d.ts +0 -1
  245. package/src/util/asyncFilter.js +0 -7
  246. package/src/util/channel-api-relay.d.ts +0 -13
  247. package/src/util/channel-api-relay.js +0 -47
  248. package/src/util/errors.d.ts +0 -10
  249. package/src/util/errors.js +0 -12
  250. package/src/util/exhaustive.d.ts +0 -1
  251. package/src/util/exhaustive.js +0 -7
  252. package/src/util/http.d.ts +0 -11
  253. package/src/util/http.js +0 -90
  254. package/src/util/inaccessibleObject.d.ts +0 -2
  255. package/src/util/inaccessibleObject.js +0 -49
  256. package/src/util/lazy.d.ts +0 -34
  257. package/src/util/lazy.js +0 -54
  258. package/src/util/normalize-config.d.ts +0 -3
  259. package/src/util/normalize-config.js +0 -52
  260. package/src/util/promises.d.ts +0 -5
  261. package/src/util/promises.js +0 -27
  262. package/src/util/ref-counter.d.ts +0 -7
  263. package/src/util/ref-counter.js +0 -52
  264. package/src/util/reversible-map.d.ts +0 -11
  265. package/src/util/reversible-map.js +0 -49
  266. package/src/util/runtimeVersioning.d.ts +0 -3
  267. package/src/util/runtimeVersioning.js +0 -25
  268. package/src/util/utilTypes.d.ts +0 -8
  269. package/src/util/utilTypes.js +0 -2
  270. package/src/util/validate.d.ts +0 -3
  271. package/src/util/validate.js +0 -11
@@ -1,692 +0,0 @@
1
- import type * as OpenFin from '../../OpenFin';
2
- import { EmitterBase } from '../base';
3
- import { Transport } from '../../transport/transport';
4
- /**
5
- * An object representing an application. Allows the developer to create,
6
- * execute, show/close an application as well as listen to {@link OpenFin.ApplicationEvents application events}.
7
- */
8
- export declare class Application extends EmitterBase<OpenFin.ApplicationEvent> {
9
- identity: OpenFin.ApplicationIdentity;
10
- /**
11
- * @internal
12
- */
13
- _manifestUrl?: string;
14
- private window;
15
- /**
16
- * @internal
17
- */
18
- constructor(wire: Transport, identity: OpenFin.ApplicationIdentity);
19
- private windowListFromIdentityList;
20
- /**
21
- * Adds a listener to the end of the listeners array for the specified event.
22
- * @param eventType - The type of the event.
23
- * @param listener - Called whenever an event of the specified type occurs.
24
- * @param options - Option to support event timestamps.
25
- *
26
- * @function addListener
27
- * @memberof Application
28
- * @instance
29
- * @tutorial Application.EventEmitter
30
- */
31
- /**
32
- * Adds a listener to the end of the listeners array for the specified event.
33
- * @param eventType - The type of the event.
34
- * @param listener - Called whenever an event of the specified type occurs.
35
- * @param options - Option to support event timestamps.
36
- *
37
- * @function on
38
- * @memberof Application
39
- * @instance
40
- * @tutorial Application.EventEmitter
41
- */
42
- /**
43
- * Adds a one time listener for the event. The listener is invoked only the first time the event is fired, after which it is removed.
44
- * @param eventType - The type of the event.
45
- * @param listener - The callback function.
46
- * @param options - Option to support event timestamps.
47
- *
48
- * @function once
49
- * @memberof Application
50
- * @instance
51
- * @tutorial Application.EventEmitter
52
- */
53
- /**
54
- * Adds a listener to the beginning of the listeners array for the specified event.
55
- * @param eventType - The type of the event.
56
- * @param listener - The callback function.
57
- * @param options - Option to support event timestamps.
58
- *
59
- * @function prependListener
60
- * @memberof Application
61
- * @instance
62
- * @tutorial Application.EventEmitter
63
- */
64
- /**
65
- * Adds a one time listener for the event. The listener is invoked only the first time the event is fired, after which it is removed.
66
- * The listener is added to the beginning of the listeners array.
67
- * @param eventType - The type of the event.
68
- * @param listener - The callback function.
69
- * @param options - Option to support event timestamps.
70
- *
71
- * @function prependOnceListener
72
- * @memberof Application
73
- * @instance
74
- * @tutorial Application.EventEmitter
75
- */
76
- /**
77
- * Remove a listener from the listener array for the specified event.
78
- * Caution: Calling this method changes the array indices in the listener array behind the listener.
79
- * @param eventType - The type of the event.
80
- * @param listener - The callback function.
81
- * @param options - Option to support event timestamps.
82
- *
83
- * @function removeListener
84
- * @memberof Application
85
- * @instance
86
- * @tutorial Application.EventEmitter
87
- */
88
- /**
89
- * Removes all listeners, or those of the specified event.
90
- * @param eventType - The type of the event.
91
- *
92
- * @function removeAllListeners
93
- * @memberof Application
94
- * @instance
95
- * @tutorial Application.EventEmitter
96
- */
97
- /**
98
- * JumpListCategory interface
99
- * @typedef { object } JumpListCategory
100
- * @property { string } name The display title for the category. If omitted, items in this category will be placed into the standard 'Tasks' category. There can be only one such category, and it will always be displayed at the bottom of the JumpList.
101
- * @property { JumpListItem[] } items Array of JumpListItem objects
102
- */
103
- /**
104
- * @PORTED
105
- * JumpListItem interface
106
- * @typedef { object } JumpListItem
107
- * @property { string } type One of the following: "task" or "separator". Defaults to task.
108
- * @property { string } title The text to be displayed for the JumpList Item. Should only be set if type is "task".
109
- * @property { string } description Description of the task (displayed in a tooltip). Should only be set if type is "task".
110
- * @property { string } deepLink Deep link to a manifest, i.e: fins://path.to/manifest.json?$$param1=value1. See {@link https://developers.openfin.co/docs/deep-linking deep-linking} for more information.
111
- * @property { string } iconPath The absolute path to an icon to be displayed for the item, which can be an arbitrary resource file that contains an icon (e.g. .ico, .exe, .dll).
112
- * @property { number } iconIndex The index of the icon in the resource file. If a resource file contains multiple icons this value can be used to specify the zero-based index of the icon that should be displayed for this task. If a resource file contains only one icon, this property should be set to zero.
113
- */
114
- /**
115
- * Determines if the application is currently running.
116
- *
117
- * @example
118
- *
119
- * ```js
120
- * async function isAppRunning() {
121
- * const app = await fin.Application.getCurrent();
122
- * return await app.isRunning();
123
- * }
124
- * isAppRunning().then(running => console.log(`Current app is running: ${running}`)).catch(err => console.log(err));
125
- * ```
126
- */
127
- isRunning(): Promise<boolean>;
128
- /**
129
- * Closes the application and any child windows created by the application.
130
- * Cleans the application from state so it is no longer found in getAllApplications.
131
- * @param force Close will be prevented from closing when force is false and
132
- * ‘close-requested’ has been subscribed to for application’s main window.
133
- *
134
- * @example
135
- *
136
- * ```js
137
- * async function closeApp() {
138
- * const allApps1 = await fin.System.getAllApplications(); //[{uuid: 'app1', isRunning: true}, {uuid: 'app2', isRunning: true}]
139
- * const app = await fin.Application.wrap({uuid: 'app2'});
140
- * await app.quit();
141
- * const allApps2 = await fin.System.getAllApplications(); //[{uuid: 'app1', isRunning: true}]
142
- *
143
- * }
144
- * closeApp().then(() => console.log('Application quit')).catch(err => console.log(err));
145
- * ```
146
- */
147
- quit(force?: boolean): Promise<void>;
148
- private _close;
149
- /**
150
- * @deprecated use Application.quit instead
151
- * Closes the application and any child windows created by the application.
152
- * @param force - Close will be prevented from closing when force is false and ‘close-requested’ has been subscribed to for application’s main window.
153
- * @param callback - called if the method succeeds.
154
- * @param errorCallback - called if the method fails. The reason for failure is passed as an argument.
155
- *
156
- * @example
157
- *
158
- * ```js
159
- * async function closeApp() {
160
- * const app = await fin.Application.getCurrent();
161
- * return await app.close();
162
- * }
163
- * closeApp().then(() => console.log('Application closed')).catch(err => console.log(err));
164
- * ```
165
- */
166
- close(force?: boolean): Promise<void>;
167
- /**
168
- * Retrieves an array of wrapped fin.Windows for each of the application’s child windows.
169
- *
170
- * @example
171
- *
172
- * ```js
173
- * async function getChildWindows() {
174
- * const app = await fin.Application.getCurrent();
175
- * return await app.getChildWindows();
176
- * }
177
- *
178
- * getChildWindows().then(children => console.log(children)).catch(err => console.log(err));
179
- * ```
180
- */
181
- getChildWindows(): Promise<Array<OpenFin.Window>>;
182
- /**
183
- * Retrieves the JSON manifest that was used to create the application. Invokes the error callback
184
- * if the application was not created from a manifest.
185
- *
186
- * @example
187
- *
188
- * ```js
189
- * async function getManifest() {
190
- * const app = await fin.Application.getCurrent();
191
- * return await app.getManifest();
192
- * }
193
- *
194
- * getManifest().then(manifest => console.log(manifest)).catch(err => console.log(err));
195
- * ```
196
- */
197
- getManifest(): Promise<OpenFin.Manifest>;
198
- /**
199
- * Retrieves UUID of the application that launches this application. Invokes the error callback
200
- * if the application was created from a manifest.
201
- *
202
- * @example
203
- *
204
- * ```js
205
- * async function getParentUuid() {
206
- * const app = await fin.Application.start({
207
- * uuid: 'app-1',
208
- * name: 'myApp',
209
- * url: 'https://cdn.openfin.co/docs/javascript/stable/tutorial-Application.getParentUuid.html',
210
- * autoShow: true
211
- * });
212
- * return await app.getParentUuid();
213
- * }
214
- *
215
- * getParentUuid().then(parentUuid => console.log(parentUuid)).catch(err => console.log(err));
216
- * ```
217
- */
218
- getParentUuid(): Promise<string>;
219
- /**
220
- * Retrieves current application's shortcut configuration.
221
- *
222
- * @example
223
- *
224
- * ```js
225
- * async function getShortcuts() {
226
- * const app = await fin.Application.wrap({ uuid: 'testapp' });
227
- * return await app.getShortcuts();
228
- * }
229
- * getShortcuts().then(config => console.log(config)).catch(err => console.log(err));
230
- * ```
231
- */
232
- getShortcuts(): Promise<OpenFin.ShortCutConfig>;
233
- /**
234
- * Retrieves current application's views.
235
- * @experimental
236
- *
237
- * @example
238
- *
239
- * ```js
240
- * async function getViews() {
241
- * const app = await fin.Application.getCurrent();
242
- * return await app.getViews();
243
- * }
244
- * getViews().then(views => console.log(views)).catch(err => console.log(err));
245
- * ```
246
- */
247
- getViews(): Promise<Array<OpenFin.View>>;
248
- /**
249
- * Returns the current zoom level of the application.
250
- *
251
- * @example
252
- *
253
- * ```js
254
- * async function getZoomLevel() {
255
- * const app = await fin.Application.getCurrent();
256
- * return await app.getZoomLevel();
257
- * }
258
- *
259
- * getZoomLevel().then(zoomLevel => console.log(zoomLevel)).catch(err => console.log(err));
260
- * ```
261
- */
262
- getZoomLevel(): Promise<number>;
263
- /**
264
- * Returns an instance of the main Window of the application
265
- *
266
- * @example
267
- *
268
- * ```js
269
- * async function getWindow() {
270
- * const app = await fin.Application.start({
271
- * uuid: 'app-1',
272
- * name: 'myApp',
273
- * url: 'https://cdn.openfin.co/docs/javascript/stable/tutorial-Application.getWindow.html',
274
- * autoShow: true
275
- * });
276
- * return await app.getWindow();
277
- * }
278
- *
279
- * getWindow().then(win => {
280
- * win.showAt(0, 400);
281
- * win.flash();
282
- * }).catch(err => console.log(err));
283
- * ```
284
- */
285
- getWindow(): Promise<OpenFin.Window>;
286
- /**
287
- * Manually registers a user with the licensing service. The only data sent by this call is userName and appName.
288
- * @param userName - username to be passed to the RVM.
289
- * @param appName - app name to be passed to the RVM.
290
- *
291
- * @example
292
- *
293
- * ```js
294
- * async function registerUser() {
295
- * const app = await fin.Application.getCurrent();
296
- * return await app.registerUser('user', 'myApp');
297
- * }
298
- *
299
- * registerUser().then(() => console.log('Successfully registered the user')).catch(err => console.log(err));
300
- * ```
301
- */
302
- registerUser(userName: string, appName: string): Promise<void>;
303
- /**
304
- * Removes the application’s icon from the tray.
305
- *
306
- * @example
307
- *
308
- * ```js
309
- * async function removeTrayIcon() {
310
- * const app = await fin.Application.getCurrent();
311
- * return await app.removeTrayIcon();
312
- * }
313
- *
314
- * removeTrayIcon().then(() => console.log('Removed the tray icon.')).catch(err => console.log(err));
315
- * ```
316
- */
317
- removeTrayIcon(): Promise<void>;
318
- /**
319
- * Restarts the application.
320
- *
321
- * @example
322
- *
323
- * ```js
324
- * async function restartApp() {
325
- * const app = await fin.Application.getCurrent();
326
- * return await app.restart();
327
- * }
328
- * restartApp().then(() => console.log('Application restarted')).catch(err => console.log(err));
329
- * ```
330
- */
331
- restart(): Promise<void>;
332
- /**
333
- * DEPRECATED method to run the application.
334
- * Needed when starting application via {@link Application.create}, but NOT needed when starting via {@link Application.start}.
335
- *
336
- * @example
337
- *
338
- * ```js
339
- * async function run() {
340
- * const app = await fin.Application.create({
341
- * name: 'myApp',
342
- * uuid: 'app-1',
343
- * url: 'https://cdn.openfin.co/docs/javascript/stable/tutorial-Application.run.html',
344
- * autoShow: true
345
- * });
346
- * await app.run();
347
- * }
348
- * run().then(() => console.log('Application is running')).catch(err => console.log(err));
349
- * ```
350
- *
351
- * @ignore
352
- */
353
- run(): Promise<void>;
354
- private _run;
355
- /**
356
- * Instructs the RVM to schedule one restart of the application.
357
- *
358
- * @example
359
- *
360
- * ```js
361
- * async function scheduleRestart() {
362
- * const app = await fin.Application.getCurrent();
363
- * return await app.scheduleRestart();
364
- * }
365
- *
366
- * scheduleRestart().then(() => console.log('Application is scheduled to restart')).catch(err => console.log(err));
367
- * ```
368
- */
369
- scheduleRestart(): Promise<void>;
370
- /**
371
- * Sends a message to the RVM to upload the application's logs. On success,
372
- * an object containing logId is returned.
373
- *
374
- * @example
375
- *
376
- * ```js
377
- * async function sendLog() {
378
- * const app = await fin.Application.getCurrent();
379
- * return await app.sendApplicationLog();
380
- * }
381
- *
382
- * sendLog().then(info => console.log(info.logId)).catch(err => console.log(err));
383
- * ```
384
- */
385
- sendApplicationLog(): Promise<OpenFin.SendApplicationLogResponse>;
386
- /**
387
- * Sets or removes a custom JumpList for the application. Only applicable in Windows OS.
388
- * If categories is null the previously set custom JumpList (if any) will be replaced by the standard JumpList for the app (managed by Windows).
389
- * Note: If the "name" property is omitted it defaults to "tasks".
390
- * @param jumpListCategories An array of JumpList Categories to populate. If null, remove any existing JumpList configuration and set to Windows default.
391
- *
392
- *
393
- * @remarks If categories is null the previously set custom JumpList (if any) will be replaced by the standard JumpList for the app (managed by Windows).
394
- *
395
- * The bottommost item in the jumplist will always be an item pointing to the current app. Its name is taken from the manifest's
396
- * **` shortcut.name `** and uses **` shortcut.company `** as a fallback. Clicking that item will launch the app from its current manifest.
397
- *
398
- * Note: If the "name" property is omitted it defaults to "tasks".
399
- *
400
- * Note: Window OS caches jumplists icons, therefore an icon change might only be visible after the cache is removed or the
401
- * uuid or shortcut.name is changed.
402
- *
403
- * @example
404
- *
405
- * ```js
406
- * const app = fin.Application.getCurrentSync();
407
- * const appName = 'My App';
408
- * const jumpListConfig = [ // array of JumpList categories
409
- * {
410
- * // has no name and no type so `type` is assumed to be "tasks"
411
- * items: [ // array of JumpList items
412
- * {
413
- * type: 'task',
414
- * title: `Launch ${appName}`,
415
- * description: `Runs ${appName} with the default configuration`,
416
- * deepLink: 'fins://path.to/app/manifest.json',
417
- * iconPath: 'https://path.to/app/icon.ico',
418
- * iconIndex: 0
419
- * },
420
- * { type: 'separator' },
421
- * {
422
- * type: 'task',
423
- * title: `Restore ${appName}`,
424
- * description: 'Restore to last configuration',
425
- * deepLink: 'fins://path.to/app/manifest.json?$$use-last-configuration=true',
426
- * iconPath: 'https://path.to/app/icon.ico',
427
- * iconIndex: 0
428
- * },
429
- * ]
430
- * },
431
- * {
432
- * name: 'Tools',
433
- * items: [ // array of JumpList items
434
- * {
435
- * type: 'task',
436
- * title: 'Tool A',
437
- * description: 'Runs Tool A',
438
- * deepLink: 'fins://path.to/tool-a/manifest.json',
439
- * iconPath: 'https://path.to/tool-a/icon.ico',
440
- * iconIndex: 0
441
- * },
442
- * {
443
- * type: 'task',
444
- * title: 'Tool B',
445
- * description: 'Runs Tool B',
446
- * deepLink: 'fins://path.to/tool-b/manifest.json',
447
- * iconPath: 'https://path.to/tool-b/icon.ico',
448
- * iconIndex: 0
449
- * }]
450
- * }
451
- * ];
452
- *
453
- * app.setJumpList(jumpListConfig).then(() => console.log('JumpList applied')).catch(e => console.log(`JumpList failed to apply: ${e.toString()}`));
454
- * ```
455
- *
456
- * To handle deeplink args:
457
- * ```js
458
- * function handleUseLastConfiguration() {
459
- * // this handler is called when the app is being launched
460
- * app.on('run-requested', event => {
461
- * if(event.userAppConfigArgs['use-last-configuration']) {
462
- * // your logic here
463
- * }
464
- * });
465
- * // this handler is called when the app was already running when the launch was requested
466
- * fin.desktop.main(function(args) {
467
- * if(args && args['use-last-configuration']) {
468
- * // your logic here
469
- * }
470
- * });
471
- * }
472
- * ```
473
- */
474
- setJumpList(jumpListCategories: OpenFin.JumpListCategory[] | null): Promise<void>;
475
- /**
476
- * Adds a customizable icon in the system tray. To listen for a click on the icon use the `tray-icon-clicked` event.
477
- * @param icon Image URL or base64 encoded string to be used as the icon
478
- *
479
- * @example
480
- *
481
- * ```js
482
- * const imageUrl = "http://cdn.openfin.co/assets/testing/icons/circled-digit-one.png";
483
- * const base64EncodedImage = "iVBORw0KGgoAAAANSUhEUgAAAAgAAAAIAQMAAAD+wSzIAAAABlBMVEX\
484
- * ///+/v7+jQ3Y5AAAADklEQVQI12P4AIX8EAgALgAD/aNpbtEAAAAASUVORK5CYII";
485
- * const dataURL = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAAHElEQVQI12P4//8/w38GIAXDIBKE0DH\
486
- * xgljNBAAO9TXL0Y4OHwAAAABJRU5ErkJggg==";
487
- *
488
- * async function setTrayIcon(icon) {
489
- * const app = await fin.Application.getCurrent();
490
- * return await app.setTrayIcon(icon);
491
- * }
492
- *
493
- * // use image url to set tray icon
494
- * setTrayIcon(imageUrl).then(() => console.log('Setting tray icon')).catch(err => console.log(err));
495
- *
496
- * // use base64 encoded string to set tray icon
497
- * setTrayIcon(base64EncodedImage).then(() => console.log('Setting tray icon')).catch(err => console.log(err));
498
- *
499
- * // use a dataURL to set tray icon
500
- * setTrayIcon(dataURL).then(() => console.log('Setting tray icon')).catch(err => console.log(err));
501
- * ```
502
- */
503
- setTrayIcon(icon: string): Promise<void>;
504
- /**
505
- * Sets new application's shortcut configuration. Windows only.
506
- * @param config New application's shortcut configuration.
507
- *
508
- * @remarks Application has to be launched with a manifest and has to have shortcut configuration (icon url, name, etc.) in its manifest
509
- * to be able to change shortcut states.
510
- *
511
- * @example
512
- *
513
- * ```js
514
- * async function setShortcuts(config) {
515
- * const app = await fin.Application.getCurrent();
516
- * return app.setShortcuts(config);
517
- * }
518
- *
519
- * setShortcuts({
520
- * desktop: true,
521
- * startMenu: false,
522
- * systemStartup: true
523
- * }).then(() => console.log('Shortcuts are set.')).catch(err => console.log(err));
524
- * ```
525
- */
526
- setShortcuts(config: OpenFin.ShortCutConfig): Promise<void>;
527
- /**
528
- * Sets the query string in all shortcuts for this app. Requires RVM 5.5+.
529
- * @param queryString The new query string for this app's shortcuts.
530
- *
531
- * @example
532
- *
533
- * ```js
534
- * const newQueryArgs = 'arg=true&arg2=false';
535
- * const app = await fin.Application.getCurrent();
536
- * try {
537
- * await app.setShortcutQueryParams(newQueryArgs);
538
- * } catch(err) {
539
- * console.error(err)
540
- * }
541
- * ```
542
- */
543
- setShortcutQueryParams(queryString: string): Promise<void>;
544
- /**
545
- * Sets the zoom level of the application. The original size is 0 and each increment above or below represents zooming 20%
546
- * larger or smaller to default limits of 300% and 50% of original size, respectively.
547
- * @param level The zoom level
548
- *
549
- * @example
550
- *
551
- * ```js
552
- * async function setZoomLevel(number) {
553
- * const app = await fin.Application.getCurrent();
554
- * return await app.setZoomLevel(number);
555
- * }
556
- *
557
- * setZoomLevel(5).then(() => console.log('Setting a zoom level')).catch(err => console.log(err));
558
- * ```
559
- */
560
- setZoomLevel(level: number): Promise<void>;
561
- /**
562
- * Sets a username to correlate with App Log Management.
563
- * @param username Username to correlate with App's Log.
564
- *
565
- * @example
566
- *
567
- * ```js
568
- * async function setAppLogUser() {
569
- * const app = await fin.Application.getCurrent();
570
- * return await app.setAppLogUsername('username');
571
- * }
572
- *
573
- * setAppLogUser().then(() => console.log('Success')).catch(err => console.log(err));
574
- *
575
- * ```
576
- */
577
- setAppLogUsername(username: string): Promise<void>;
578
- /**
579
- * Retrieves information about the system tray. If the system tray is not set, it will throw an error message.
580
- * @remarks The only information currently returned is the position and dimensions.
581
- *
582
- * @example
583
- *
584
- * ```js
585
- * async function getTrayIconInfo() {
586
- * const app = await fin.Application.wrap({ uuid: 'testapp' });
587
- * return await app.getTrayIconInfo();
588
- * }
589
- * getTrayIconInfo().then(info => console.log(info)).catch(err => console.log(err));
590
- * ```
591
- */
592
- getTrayIconInfo(): Promise<OpenFin.TrayInfo>;
593
- /**
594
- * Checks if the application has an associated tray icon.
595
- *
596
- * @example
597
- *
598
- * ```js
599
- * const app = await fin.Application.wrap({ uuid: 'testapp' });
600
- * const hasTrayIcon = await app.hasTrayIcon();
601
- * console.log(hasTrayIcon);
602
- * ```
603
- */
604
- hasTrayIcon(): Promise<boolean>;
605
- /**
606
- * Closes the application by terminating its process.
607
- *
608
- * @example
609
- *
610
- * ```js
611
- * async function terminateApp() {
612
- * const app = await fin.Application.getCurrent();
613
- * return await app.terminate();
614
- * }
615
- * terminateApp().then(() => console.log('Application terminated')).catch(err => console.log(err));
616
- * ```
617
- */
618
- terminate(): Promise<void>;
619
- /**
620
- * Waits for a hanging application. This method can be called in response to an application
621
- * "not-responding" to allow the application to continue and to generate another "not-responding"
622
- * message after a certain period of time.
623
- *
624
- * @ignore
625
- */
626
- wait(): Promise<void>;
627
- /**
628
- * Retrieves information about the application.
629
- *
630
- * @remarks If the application was not launched from a manifest, the call will return the closest parent application `manifest`
631
- * and `manifestUrl`. `initialOptions` shows the parameters used when launched programmatically, or the `startup_app` options
632
- * if launched from manifest. The `parentUuid` will be the uuid of the immediate parent (if applicable).
633
- *
634
- * @example
635
- *
636
- * ```js
637
- * async function getInfo() {
638
- * const app = await fin.Application.getCurrent();
639
- * return await app.getInfo();
640
- * }
641
- *
642
- * getInfo().then(info => console.log(info)).catch(err => console.log(err));
643
- * ```
644
- */
645
- getInfo(): Promise<OpenFin.ApplicationInfo>;
646
- /**
647
- * Retrieves all process information for entities (windows and views) associated with an application.
648
- *
649
- * @example
650
- * ```js
651
- * const app = await fin.Application.getCurrent();
652
- * const processInfo = await app.getProcessInfo();
653
- * ```
654
- * @experimental
655
- */
656
- getProcessInfo(): Promise<OpenFin.AppProcessInfo>;
657
- /**
658
- * Sets file auto download location. It's only allowed in the same application.
659
- * Note: This method is restricted by default and must be enabled via
660
- * <a href="https://developers.openfin.co/docs/api-security">API security settings</a>.
661
- * @param downloadLocation file auto download location
662
- *
663
- * @throws if setting file auto download location on different applications.
664
- * @example
665
- *
666
- * ```js
667
- * const downloadLocation = 'C:\\dev\\temp';
668
- * const app = await fin.Application.getCurrent();
669
- * try {
670
- * await app.setFileDownloadLocation(downloadLocation);
671
- * console.log('File download location is set');
672
- * } catch(err) {
673
- * console.error(err)
674
- * }
675
- * ```
676
- */
677
- setFileDownloadLocation(downloadLocation: string): Promise<void>;
678
- /**
679
- * Gets file auto download location. It's only allowed in the same application. If file auto download location is not set, it will return the default location.
680
- * Note: This method is restricted by default and must be enabled via
681
- * <a href="https://developers.openfin.co/docs/api-security">API security settings</a>.
682
- *
683
- * @throws if getting file auto download location on different applications.
684
- * @example
685
- *
686
- * ```js
687
- * const app = await fin.Application.getCurrent();
688
- * const fileDownloadDir = await app.getFileDownloadLocation();
689
- * ```
690
- */
691
- getFileDownloadLocation(): Promise<string>;
692
- }