2 Komitmen 9b9079eb03 ... c8769a6378

Pembuat SHA1 Pesan Tanggal
  fr33domlover c8769a6378 Vocabulary spec: Add property 'currentVersion' 4 tahun lalu
  fr33domlover fae153dccb Vocabulary spec: Add property 'previousVersions' 4 tahun lalu
2 mengubah file dengan 78 tambahan dan 3 penghapusan
  1. 10 3
      rdf/context.jsonld
  2. 68 0
      spec/vocabulary.md

+ 10 - 3
rdf/context.jsonld

@@ -17,12 +17,22 @@
         "earlyItems": {
             "@id": "forge:earlyItems",
             "@type": "@id" },
+        "previousVersions": {
+            "@id": "forge:previousVersions",
+            "@type": "@id",
+            "@container": "@list" },
+        "currentVersion": {
+            "@id": "forge:currentVersion",
+            "@type": "@id" },
         "assignedTo": {
             "@id": "forge:assignedTo",
             "@type": "@id" },
         "isResolved": {
             "@id": "forge:isResolved",
             "@type": "xsd:boolean" },
+        "resolvedBy": {
+            "@id": "forge:resolvedBy",
+            "@type": "@id" },
         "dependsOn": {
             "@id": "forge:dependsOn",
             "@type": "@id" },
@@ -59,9 +69,6 @@
         "ref": {
             "@id": "forge:ref",
             "@type": "xsd:string" },
-        "resolvedBy": {
-            "@id": "forge:resolvedBy",
-            "@type": "@id" },
         "team": {
             "@id": "forge:team",
             "@type": "@id" },

+ 68 - 0
spec/vocabulary.md

@@ -297,6 +297,74 @@ examle, if `items` lists items in reverse chronogical order, then so does
 }
 ```
 
+## previousVersions {#prop-previousversions}
+
+**URI:** `https://forgefed.peers.community/ns#previousVersions`
+
+**Notes** Specifies the previous versions of the subject, as an ordered list in
+reverse chronological order.
+
+**Domain:** [Object][]
+
+**Range:** `rdf:List` of objects of the same `@type` as the subject
+
+**Functional:** Yes
+
+**Inverse of:** (None, but see [currentVersion](#prop-currentversion))
+
+**Example:**
+
+```json
+{
+    "@context": [
+        "https://www.w3.org/ns/activitystreams",
+        "https://forgefed.peers.community/ns"
+    ],
+    "id": "https://dev.example/aviva/notes/107",
+    "type": "Note",
+    "attributedTo": "https://dev.example/aviva",
+    "content": "I agree!!!!! (edit: fixed a typo)",
+    "previousVersions": [
+       "https://dev.example/aviva/notes/107_old_version",
+       "https://dev.example/aviva/notes/107_very_old_version",
+       "https://dev.example/aviva/notes/107_ancient_version"
+    ]
+}
+```
+
+## currentVersion {#prop-currentversion}
+
+**URI:** `https://forgefed.peers.community/ns#currentVersion`
+
+**Notes** Specifies the latest. current, up-to-date version of the subject.
+Once the subject specifies the `currentVersion` property, it SHOULD NOT get any
+changes to any other properties. The exception is `currentVersion` itself,
+which MUST be updated whenever needed, to always point to the latest version.
+
+**Domain:** [Object][]
+
+**Range:** [Object][], of the same `@type` as the subject
+
+**Functional:** Yes
+
+**Inverse of:** (None, but see [previousVersions](#prop-previousversions))
+
+**Example:**
+
+```json
+{
+    "@context": [
+        "https://www.w3.org/ns/activitystreams",
+        "https://forgefed.peers.community/ns"
+    ],
+    "id": "https://dev.example/aviva/notes/107_old_version",
+    "type": "Note",
+    "attributedTo": "https://dev.example/aviva",
+    "content": "I agree!!111",
+    "currentVersion": "https://dev.example/aviva/notes/107"
+}
+```
+
 ## assignedTo {#prop-assignedto}
 
 **URI:** `https://forgefed.peers.community/ns#assignedTo`