on master help sign in
Review: update out-of-date post.hoon `sur` file
3a77db9Yaseen
userspace/graph-store/sur-file-walkthrough.md+18−9
@@ -38,15 +38,19 @@ Here's `sur/post.hoon`
38 contents=(list content)
38 contents=(list content)
39 ==
39 ==
40::
40::
41++$ reference
42+ $% [%graph group=resource =uid]
43+ [%group group=resource]
44+ ==
45+::
41+$ content
46+$ content
42 $% [%text text=cord]
47 $% [%text text=cord]
43 [%mention =ship]
48 [%mention =ship]
44 [%url url=cord]
49 [%url url=cord]
45 [%code expression=cord output=(list tank)]
50 [%code expression=cord output=(list tank)]
46− [%reference =uid]
51+ [%reference =reference]
47− :: TODO: maybe use a cask?
48− ::[%cage =cage]
49 ==
52 ==
53+--
50```
54```
51
55
52
56
@@ -75,27 +79,32 @@ These types are used to cryptographically sign a given post, so that the host of
75
79
76### Content Types
80### Content Types
77```
81```
82++$ reference
83+ $% [%graph group=resource =uid]
84+ [%group group=resource]
85+ ==
86+::
78+$ content
87+$ content
79 $% [%text text=cord]
88 $% [%text text=cord]
80 [%mention =ship]
89 [%mention =ship]
81 [%url url=cord]
90 [%url url=cord]
82 [%code expression=cord output=(list tank)]
91 [%code expression=cord output=(list tank)]
83− [%reference =uid]
92+ [%reference =reference]
84− :: TODO: maybe use a cask?
85− ::[%cage =cage]
86 ==
93 ==
87−--
94+::
88```
95```
89
96
97+`reference` is a type that models a reference to a graph object. Currently, the valid types of references are either a reference to a specific node in a graph, or a specific group.
98+
90`content` enumerates all the possible content types that a post can have. The possible content types can be:
99`content` enumerates all the possible content types that a post can have. The possible content types can be:
91
100
92- **Text** - representing plain text content
101- **Text** - representing plain text content
93- **Url** - specific data type for urls
102- **Url** - specific data type for urls
94- **Mention** - mentioning another ship
103- **Mention** - mentioning another ship
95- **Code** - a pair of a piece of code that was executed and its result (static data, no execution takes place inside of Graph Store)
104- **Code** - a pair of a piece of code that was executed and its result (static data, no execution takes place inside of Graph Store)
96−- **Reference** - a reference to another post. Uses the `uid` type under the hood
105+- **Reference** - a reference to another post, using the `reference` type
97
106
98−Currently, these are the only content types supported by Graph Store, although there is potential for dynamic content support in the form of a `cage`.
107+Currently, these are the only content types supported by Graph Store.
99
108
100### Post
109### Post
101```
110```