shrub/pkg/arvo/mar/graph/validator/chat.hoon

44 lines
862 B
Plaintext
Raw Normal View History

/- *post, met=metadata-store, graph=graph-store, hark=hark-graph-hook
|_ i=indexed-post
++ grow
|%
++ noun i
2021-01-26 07:50:33 +03:00
::
++ graph-permissions-add
|= vip=vip-metadata:met
^- permissions:graph
2021-01-26 07:50:33 +03:00
?+ index.p.i !!
[@ ~] [%yes %yes %no]
==
::
++ graph-permissions-remove
|= vip=vip-metadata:met
^- permissions:graph
2021-01-26 07:50:33 +03:00
?+ index.p.i !!
[@ ~] [%self %self %no]
==
::
2020-11-24 08:39:53 +03:00
++ notification-kind
^- (unit notif-kind:hark)
2020-11-24 08:39:53 +03:00
?+ index.p.i ~
[@ ~] `[%message [0 1] %count %none]
2020-11-24 08:39:53 +03:00
==
::
++ transform-add-nodes
|= [=index =post =atom was-parent-modified=?]
^- [^index ^post]
=- [- post(index -)]
[atom ~]
--
++ grab
|%
++ noun
|: p=`*`%*(. *indexed-post index.p [0 ~])
=/ ip ;;(indexed-post p)
?> ?=([@ ~] index.p.ip)
ip
--
::
++ grad %noun
--