Skip to content

Commit

Permalink
Merge branch 'master' into 651-currency-context
Browse files Browse the repository at this point in the history
  • Loading branch information
kriswest committed May 20, 2022
2 parents 19fefd7 + 7ae5b80 commit 04a62d1
Show file tree
Hide file tree
Showing 49 changed files with 3,252 additions and 2,644 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
node_modules
dist
coverage
.project

lib/core/metadata.js
lib/core/MetadataBlog.js
Expand Down
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
* `IntentResolution` now requires the name of the intent raised to included, allowing it to be used to determine the intent raised via `fdc3.raiseIntentForContext()`. ([#507](https://github.com/finos/FDC3/pull/507))
* A Trademarks page was added to acknowledge trademarks used within the Standard not owned by FINOS or the Linux Foundation ([#534](https://github.com/finos/FDC3/pull/534))
* Added details of FDC3's existing versioning and deprecation policies to the FDC3 compliance page ([#539](https://github.com/finos/FDC3/pull/539))
* Added a new experimental features policy, which exempts features designated as experimental from the versioning and deprecation policies, to the FDC3 compliance page ([#549](https://github.com/finos/FDC3/pull/549))
* Add `IntentDeliveryFailed` to the `ResolveError` enumeration to be used when delivery of an intent and context to a targetted app or instance fails. ([#601](https://github.com/finos/FDC3/pull/601))
* Added a context type representing a Currency. ([#708](https://github.com/finos/FDC3/pull/708))

Expand Down
78 changes: 0 additions & 78 deletions docs/api/overview.md

This file was deleted.

13 changes: 9 additions & 4 deletions docs/api/ref/Channel.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ Channels each have a unique identifier, some display metadata and operations for
interface Channel {
// properties
id: string;
type: string;
type: "user" | "app" | "private";
displayMetadata?: DisplayMetadata;

// methods
Expand Down Expand Up @@ -51,10 +51,10 @@ Uniquely identifies the channel. It is either assigned by the desktop agent (Use
### `type`

```ts
public readonly type: string;
public readonly type: "user" | "app" | "private";
```

Can be _system_, _app_ or _private_.
Can be _user_, _app_ or _private_.

### `displayMetadata`

Expand All @@ -65,15 +65,18 @@ public readonly displayMetadata?: DisplayMetadata;
DisplayMetadata can be used to provide display hints for User Channels intended to be visualized and selectable by end users.

#### See also

* [`DisplayMetadata`](Metadata#displaymetadata)

## Methods


### `addContextListener`

```ts
public addContextListener(contextType: string | null, handler: ContextHandler): Promise<Listener>;
```

Adds a listener for incoming contexts of the specified _context type_ whenever a broadcast happens on this channel.

If, when this function is called, the channel already contains context that would be passed to the listener it is NOT called or passed this context automatically (this behavior differs from that of the [`fdc3.addContextListener`](DesktopAgent#addcontextlistener) function). Apps wishing to access to the current context of the channel should instead call the [`getCurrentContext(contextType)`](#getcurrentcontext) function.
Expand Down Expand Up @@ -122,6 +125,7 @@ instrumentListener.unsubscribe();
```

#### See also

* [`Listener`](Types#listener)
* [`ContextHandler`](Types#contexthandler)
* [`broadcast`](#broadcast)
Expand Down Expand Up @@ -159,6 +163,7 @@ try {
```

#### See also

* [`ChannelError`](Errors#channelerror)
* [`getCurrentContext`](#getcurrentcontext)
* [`addContextListener`](#addcontextlistener)
Expand All @@ -175,7 +180,6 @@ If no _context type_ is provided, the most recent context that was broadcast on

It is up to the specific Desktop Agent implementation whether and how recent contexts are stored. For example, an implementation could store context history for a channel in a single array and search through the array for the last context matching a provided type, or context could be maintained as a dictionary keyed by context types. An implementation could also choose not to support context history, in which case this method will return `null` for any context type not matching the type of the most recent context.


If getting the current context fails, the promise will return an `Error` with a string from the [`ChannelError`](ChannelError) enumeration.

#### Examples
Expand All @@ -201,6 +205,7 @@ try {
```

#### See also

* [`ChannelError`](Errors#channelerror)
* [`broadcast`](#broadcast)
* [`addContextListener`](#addcontextlistener)
Expand Down
10 changes: 5 additions & 5 deletions docs/api/ref/Metadata.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,8 @@ interface AppIntent {
An interface that represents the binding of an intent to apps, returned as part of intent disocvery.
For each intent, it reference the applications that support that intent.

### See also
* [`AppMetadata`]#appmetadata)
#### See also
* [`AppMetadata`](#appmetadata)
* [`IntentMetadata`](#intentmetadata)
* [`DesktopAgent.findIntent`](DesktopAgent#findintent)
* [`DesktopAgent.findIntentsByContext`](DesktopAgent#findintentsbycontext)
Expand Down Expand Up @@ -120,7 +120,7 @@ interface ImplementationMetadata {

Metadata relating to the FDC3 [DesktopAgent](DesktopAgent) object and its provider, including the supported version of the FDC3 specification and the name of the provider of the implementation.

### See also
#### See also
* [`DesktopAgent.getInfo`](DesktopAgent#getinfo)

## `IntentMetadata`
Expand All @@ -137,7 +137,7 @@ interface IntentMetadata {
The interface used to describe an intent within the platform.


### See also
#### See also
* [`AppIntent.intent`](#appintent)

## `IntentResolution`
Expand Down Expand Up @@ -212,7 +212,7 @@ try {
}
```

### See also
#### See also
* [`DesktopAgent.raiseIntent`](DesktopAgent#raiseintent)
* [`DesktopAgent.raiseIntentForContext`](DesktopAgent#raiseintentforcontext)
* [`TargetApp`](Types#targetapp)
Loading

0 comments on commit 04a62d1

Please sign in to comment.