w3c / w3c/activitystreams

Disjointness of Activity Streams types

Open
#641 4 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Needs primer page Next version
Dominant language
HTML
Stars
313
Forks
70
PR merge metrics
No merged PRs in 30d

Description

Activity Streams 2.0 defines 8 core types and a bigger number of extended types. All of them are sub-types of either Object or Link, which are described as disjoint, but specification doesn't say anything about disjointedness of derived types.

There are two situations where disjointness may matter:

  • Sub-typing. Is it possible to define a new type that extends two or more core types (e.g. Activity and Collection)?
  • Multi-typing. Is it possible to create an object with two or more extended types (e.g. ["Accept", "Person"])?

Most (if not all) of these combinations don't make sense, and as an implementer I would prefer to not deal with them, and fortunately I don't have to, because existing implementations don't use combinations. However, while there is no guidance on working with combinations of standard types, they are not explicitly forbidden. One of the core types, OrderedCollectionPage, is even defined as a sub-type of both OrderedCollection and CollectionPage, implying that multiple inheritance is possible.

Proposal

  • Discourage the use of type combinations in a Primer page (both multiple inheritance and multi-typing). Note that this only applies to standard types; for extension types, multi-typing is required by the standard.
  • Make this a requirement in AS-next. Re-define OrderedCollectionPage as a sub-type of CollectionPage.

Further work (optional)

  • Introduce Actor core type, which is disjoint with Activity and Collection (discussion).
  • Introduce SpecializedObject core type, which extends Object and is disjoint with Activity, Collection and Actor.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reading the Activity Streams 2.0 core and vocabulary sections linked in the issue, then review the proposed Primer guidance and AS-next change. Done would mean reaching agreement on how standard-type combinations should be handled and documenting the decision, including the OrderedCollectionPage relationship.

Written by the indexing model from the issue text.

Assessment

Domain
documentation
Issue type
Documentation
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.