Skip to content

Commit

Permalink
Merge branch 'finos:master' into tpina_544_DAB_update
Browse files Browse the repository at this point in the history
  • Loading branch information
kriswest authored Jun 7, 2022
2 parents 29439ce + 1f935ff commit ea8aaa4
Show file tree
Hide file tree
Showing 125 changed files with 7,482 additions and 3,559 deletions.
4 changes: 4 additions & 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 All @@ -13,3 +14,6 @@ website/static/toolbox
website/node_modules
website/i18n/*
website/package-lock.json

.idea/
*.iml
118 changes: 87 additions & 31 deletions CHANGELOG.md

Large diffs are not rendered by default.

17 changes: 9 additions & 8 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,17 +7,17 @@ _NOTE:_ Commits and pull requests to FINOS repositories will only be accepted fr
*Need an ICLA? Unsure if you are covered under an existing CCLA? Email [help@finos.org](mailto:help@finos.org).*


## 1. Contribution Guidelines.
## 1. Contribution Guidelines.

This Working Group accepts contributions via pull requests. The following section outlines the process for merging contributions to the specification

**1.1. Issues.** Issues are used as the primary method for tracking anything to do with this specification Working Group.
**1.1. Issues.** Issues are used as the primary method for tracking anything to do with this specification Working Group.

**1.1.1. Issue Types.** A number of issue templates are available in the FDC3 respository:

**1.1.1.1. Meetings.** Templates for issues that represent meetings and include agendas, teleconference details and minutes.

**1.1.1.2. Proposals and Enhancement Requests.** Used for items that propose a new ideas or functionality that require a larger discussion. This allows for feedback from others before a specification change is actually written.
**1.1.1.2. Proposals and Enhancement Requests.** Used for items that propose a new ideas or functionality that require a larger discussion. This allows for feedback from others before a specification change is actually written.

**1.1.1.3. Minor Issue:** These track minor changes or corrections that don't alter the Standard significantly but rather correct minor errors or ommisions.

Expand All @@ -33,7 +33,7 @@ The issue lifecycle is mainly driven by the Maintainer. All issue types follow t

- The FDC3 Maintainers will apply the proper labels for the issue. This may include labels for priority, type, and metadata.

- (If needed) Clean up the title to succinctly and clearly state the issue.
- (If needed) Clean up the title to succinctly and clearly state the issue.

**2.3. Discussion.**

Expand All @@ -47,13 +47,13 @@ The issue lifecycle is mainly driven by the Maintainer. All issue types follow t

The Working Group uses pull requests to track changes. To submit a change to the Standard:

**3.1. Fork the Repo**
**3.1. Fork the Repo**
- (<https://github.com/finos/FDC3/fork>)

**3.2. Create your feature branch**
- `git checkout -b feature/fooBar`

**3.3. Commit your changes**
**3.3. Commit your changes**
- `git commit -am 'Describe what you changed'`

**3.4. Push to the branch**
Expand All @@ -62,6 +62,7 @@ The Working Group uses pull requests to track changes. To submit a change to the
**3.5. Create a Pull Request**
- For help creating a pull request from your fork, [see Github's documentation](https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/proposing-changes-to-your-work-with-pull-requests/creating-a-pull-request-from-a-fork)

To contribute a patch for a New Intent, see the [Submit New Intent](docs/guides/submit-new-intent) guide.

## 4. Pull Request Workflow.

Expand All @@ -78,13 +79,13 @@ The next section contains more information on the workflow followed for Pull Req

**4.2. Triage**

- The Maintainers will apply the proper labels for the issue. This may include an indication of the subject area or type (e.g. `deprecation`).
- The Maintainers will apply the proper labels for the issue. This may include an indication of the subject area or type (e.g. `deprecation`).

**4.3. Reviewing/Discussion.**

- All PRs will be reviewed by at least one of the FDC3 Maintainers and any appointed Editors. PRs are also open to review by FDC3 Participants.

- The FDC3 Maintainers are responsible for ensuring that the the Standard Working Group has been consulted on either an issue (that provides a high-level of detail on the proposed changes) or on the PR itself, a decision has been reached that the change should be made and that that decision has been documented.
- The FDC3 Maintainers are responsible for ensuring that the Standard Working Group has been consulted on either an issue (that provides a high-level of detail on the proposed changes) or on the PR itself, a decision has been reached that the change should be made and that that decision has been documented.

- All reviews will be completed using the Github review tool.

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

This file was deleted.

46 changes: 30 additions & 16 deletions docs/api/ref/Channel.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,13 +16,15 @@ 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
// functions
broadcast(context: Context): Promise<void>;
getCurrentContext(contextType?: string): Promise<Context|null>;
addContextListener(contextType: string | null, handler: ContextHandler): Promise<Listener>;

//deprecated functions
/**
* @deprecated Use `addContextListener(null, handler)` instead of `addContextListener(handler)`
*/
Expand Down Expand Up @@ -51,10 +53,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,28 +67,22 @@ 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
* [`DisplayMetadata`](Metadata#displaymetadata)

## Functions

### `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.


```ts
/**
* @deprecated Use `addContextListener(null, handler)` instead of `addContextListener(handler)`
*/
public addContextListener(handler: ContextHandler): Promise<Listener>;
```
Adds a listener for incoming contexts whenever a broadcast happens on the channel.

Optional metadata about each context message received, including the app that originated the message, SHOULD be provided by the desktop agent implementation.

#### Examples

Expand Down Expand Up @@ -122,6 +118,7 @@ instrumentListener.unsubscribe();
```

#### See also

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

#### See also

* [`ChannelError`](Errors#channelerror)
* [`getCurrentContext`](#getcurrentcontext)
* [`addContextListener`](#addcontextlistener)
Expand All @@ -175,7 +173,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,7 +198,24 @@ try {
```

#### See also

* [`ChannelError`](Errors#channelerror)
* [`broadcast`](#broadcast)
* [`addContextListener`](#addcontextlistener)

## Deprecated Functions

### `addContextListener` (deprecated)

```ts
/**
* @deprecated Use `addContextListener(null, handler)` instead of `addContextListener(handler)`
*/
public addContextListener(handler: ContextHandler): Promise<Listener>;
```

Adds a listener for incoming contexts whenever a broadcast happens on the channel.

#### See also

* [`addContextListener`](#addcontextlistener)
Loading

0 comments on commit ea8aaa4

Please sign in to comment.