on master help sign in
remove public interface section
commit3627baf6be93f3c5bca8de5ec88486edf6de12f0 authordrbeefsupreme <drbeefsupreme@discordja.net> dateThu 8 Apr 2021, 15:45 (6 years ago) parent5178013
1 file changed−102
arvo/clay/data-types.md−102
arvo/clay/data-types.md−102
@@ -664,105 +664,3 @@ revision number, whichever is smaller.
664664
665665`lar` is the set of new commits, and `bar` is the set of new content.
666666
667−## Public Interface
668−
669−As with all vanes, there are exactly two ways to interact with clay.
670−`%clay` exports a namespace accessible through `.^`, which is described
671−above under `++care:clay`. The primary way of interacting with clay, though,
672−is by sending kisses and receiving gifts.
673−
674−```hoon
675− ++ gift :: out result <-$
676− $% [%ergo p=@p q=@tas r=@ud] :: version update
677− [%note p=@tD q=tank] :: debug message
678− [%writ p=riot] :: response
679− == ::
680− ++ kiss :: in request ->$
681− $% [%info p=@p q=@tas r=nori] :: internal edit
682− [%ingo p=@p q=@tas r=nori] :: internal noun edit
683− [%init p=@p] :: report install
684− [%into p=@p q=@tas r=nori] :: external edit
685− [%invo p=@p q=@tas r=nori] :: external noun edit
686− [%merg p=@p q=@tas r=mizu] :: internal change
687− [%wart p=sock q=@tas r=path s=*] :: network request
688− [%warp p=sock q=riff] :: file request
689− == ::
690−```
691−
692−There are only a small number of possible kisses, so it behooves us to
693−describe each in detail.
694−
695−```hoon
696− $% [%info p=@p q=@tas r=nori] :: internal edit
697−
698− [%into p=@p q=@tas r=nori] :: external edit
699−```
700−
701−These two kisses are nearly identical. At a high level, they apply
702−changes to the filesystem. Whenever we add, remove, or edit a file, one
703−of these cards is sent. The `p` is the ship whose filesystem we're
704−trying to change, the `q` is the desk we're changing, and the `r` is the
705−request change. For the format of the requested change, see the
706−documentation for `++nori:clay` above.
707−
708−When a file is changed in the unix filesystem, vere will send a `%into`
709−kiss. This tells Clay that the duct over which the kiss was sent is the
710−duct that unix is listening on for changes. From within Arvo, though, we
711−should never send a `%into` kiss. The `%info` kiss is exactly identical
712−except it does not reset the duct.
713−
714−```hoon
715− [%ingo p=@p q=@tas r=nori] :: internal noun edit
716−
717− [%invo p=@p q=@tas r=nori] :: external noun edit
718−```
719−
720−These kisses are currently identical to `%info` and `%into`, though this
721−will not always be the case. The intent is for these kisses to allow
722−typed changes to Clay so that we may store typed data. This is currently
723−unimplemented.
724−
725−```hoon
726− [%init p=@p] :: report install
727−```
728−
729−Init is called when a ship is started on our pier. This simply creates a
730−default `room` to go into our `raft`. Essentially, this initializes the
731−filesystem for a ship.
732−
733−```hoon
734− [%merg p=@p q=@tas r=mizu] :: internal change
735−```
736−
737−This is called to perform a merge. This is most visibly called by
738−:update to update the filesystem of the current ship to that of its
739−sein. The `p` and `q` are as in `%info`, and the `r` is the description
740−of the merge. See `++mizu:clay` above.
741−
742−XX
743−`XX [%wake ~] :: timer activate XX`
744−XX\
745−XX This card is sent by unix at the time specified by `++doze`. This
746−time is XX usually the closest time specified in a subscription request.
747−When `%wake` is XX called, we update our subscribers if there have been
748−any changes.
749−
750−```hoon
751− [%wart p=sock q=@tas r=path s=*] :: network request
752−```
753−
754−This is a request that has come across the network for a particular
755−file. When another ship asks for a file from us, that request comes to
756−us in the form of a `%wart` kiss. This is handled by trivially turning
757−it into a `%warp`.
758−
759−```hoon
760− [%warp p=sock q=riff] :: file request
761−```
762−
763−This is a request for information about a particular desk. This is, in
764−its most general form, a subscription, though in many cases it is the
765−trivial case of a subscription -- a read. See `++riff:clay` for the format of
766−the request.
767−
768−