diff --git a/protocols/schemas/dataspace.prs b/protocols/schemas/dataspace.prs new file mode 100644 index 0000000..55866c5 --- /dev/null +++ b/protocols/schemas/dataspace.prs @@ -0,0 +1,4 @@ +version 1 . +embeddedType EntityRef.Ref . + +Observe = . diff --git a/protocols/schemas/dataspacePatterns.prs b/protocols/schemas/dataspacePatterns.prs new file mode 100644 index 0000000..bfba3ad --- /dev/null +++ b/protocols/schemas/dataspacePatterns.prs @@ -0,0 +1,15 @@ +version 1 . + +; Dataspace patterns: a sublanguage of attenuation patterns. +Pattern = DDiscard / DBind / DLit / DCompound . + +DDiscard = <_>. +DBind = . +DLit = . +DCompound = @rec + / @arr + / @dict . + +CRec = . +CArr = . +CDict = . diff --git a/protocols/schemas/gatekeeper.prs b/protocols/schemas/gatekeeper.prs new file mode 100644 index 0000000..a25d6c3 --- /dev/null +++ b/protocols/schemas/gatekeeper.prs @@ -0,0 +1,5 @@ +version 1 . +embeddedType EntityRef.Ref . + +Resolve = . +Bind = . diff --git a/protocols/schemas/protocol.prs b/protocols/schemas/protocol.prs new file mode 100644 index 0000000..b86a66d --- /dev/null +++ b/protocols/schemas/protocol.prs @@ -0,0 +1,14 @@ +version 1 . +embeddedType sturdy.WireRef . + +Assertion = any . +Handle = int . +Event = Assert / Retract / Message / Sync . +Oid = int . +Turn = [TurnEvent ...]. +TurnEvent = [@oid Oid @event Event]. + +Assert = . +Retract = . +Message = . +Sync = . diff --git a/protocols/schemas/racketEvent.prs b/protocols/schemas/racketEvent.prs new file mode 100644 index 0000000..36985a7 --- /dev/null +++ b/protocols/schemas/racketEvent.prs @@ -0,0 +1,3 @@ +version 1 . + +RacketEvent = . diff --git a/protocols/schemas/secureChatProtocol.prs b/protocols/schemas/secureChatProtocol.prs new file mode 100644 index 0000000..09e9e7e --- /dev/null +++ b/protocols/schemas/secureChatProtocol.prs @@ -0,0 +1,21 @@ +version 1 . +embeddedType EntityRef.Ref . + +UserId = int . + +Join = . + +Session = @observeUsers + / @observeSpeech + / NickClaim + / Says +. + +NickClaim = . +NickClaimResponse = #t / NickConflict . + +UserInfo = . + +Says = . + +NickConflict = . diff --git a/protocols/schemas/service.prs b/protocols/schemas/service.prs new file mode 100644 index 0000000..11ac336 --- /dev/null +++ b/protocols/schemas/service.prs @@ -0,0 +1,5 @@ +version 1 . +embeddedType EntityRef.Ref . + +RequireService = . +ServiceRunning = . diff --git a/protocols/schemas/simpleChatProtocol.prs b/protocols/schemas/simpleChatProtocol.prs new file mode 100644 index 0000000..33804eb --- /dev/null +++ b/protocols/schemas/simpleChatProtocol.prs @@ -0,0 +1,5 @@ +version 1 . +embeddedType EntityRef.Ref . + +Present = . +Says = . diff --git a/protocols/schemas/stream.prs b/protocols/schemas/stream.prs new file mode 100644 index 0000000..a8c7ecc --- /dev/null +++ b/protocols/schemas/stream.prs @@ -0,0 +1,38 @@ +version 1 . +embeddedType EntityRef.Ref . + +; Assertion: +StreamConnection = . + +; Assertions: +StreamListenerReady = . +StreamListenerError = . + +; Assertion: +StreamError = . + +Source = + ; Assertions: + / + / StreamError + + ; Messages: + / +. + +Sink = + ; Assertions: + / + / StreamError + + ; Messages: + / + / +. + +; Value: +CreditAmount = @count int / @unbounded =unbounded . + +; Value: +Mode = =bytes / @lines LineMode / / . +LineMode = =lf / =crlf . diff --git a/protocols/schemas/sturdy.prs b/protocols/schemas/sturdy.prs new file mode 100644 index 0000000..f82dd4e --- /dev/null +++ b/protocols/schemas/sturdy.prs @@ -0,0 +1,44 @@ +version 1 . + +; Each Attenuation is a stage. The sequence of Attenuations is run RIGHT-TO-LEFT. +; That is, the newest Attenuations are at the right. +SturdyRef = . + +; An individual Attenuation is run RIGHT-TO-LEFT. +; That is, the newest Caveats are at the right. +Attenuation = [Caveat ...]. + +; embodies 1st-party caveats over assertion structure, but nothing else +; can add 3rd-party caveats and richer predicates later +Caveat = Rewrite / Alts . +Rewrite = . +Alts = . + +Oid = int . +WireRef = @mine [0 @oid Oid] / @yours [1 @oid Oid @attenuation Caveat ...]. + +;--------------------------------------------------------------------------- + +ConstructorSpec = CRec / CArr / CDict . +CRec = . +CArr = . +CDict = . + +Lit = . + +Pattern = PDiscard / PAtom / PEmbedded / PBind / PAnd / PNot / Lit / PCompound . +PDiscard = <_>. +PAtom = =Boolean / =Float / =Double / =SignedInteger / =String / =ByteString / =Symbol . +PEmbedded = =Embedded . +PBind = . +PAnd = . +PNot = . +PCompound = . +PCompoundMembers = { any: Pattern ...:... }. + +Template = TAttenuate / TRef / Lit / TCompound . +TAttenuate = . +TRef = . +TCompound = . +TCompoundMembers = { any: Template ...:... }. + diff --git a/protocols/schemas/tcp.prs b/protocols/schemas/tcp.prs new file mode 100644 index 0000000..7a6d5e1 --- /dev/null +++ b/protocols/schemas/tcp.prs @@ -0,0 +1,7 @@ +version 1 . +embeddedType EntityRef.Ref . + +TcpRemote = . +TcpLocal = . + +TcpPeerInfo = . diff --git a/protocols/schemas/timer.prs b/protocols/schemas/timer.prs new file mode 100644 index 0000000..30ea166 --- /dev/null +++ b/protocols/schemas/timer.prs @@ -0,0 +1,7 @@ +version 1 . + +SetTimer = . +TimerExpired = . +TimerKind = =relative / =absolute / =clear . + +LaterThan = . diff --git a/protocols/schemas/worker.prs b/protocols/schemas/worker.prs new file mode 100644 index 0000000..25783b5 --- /dev/null +++ b/protocols/schemas/worker.prs @@ -0,0 +1,4 @@ +version 1 . +embeddedType EntityRef.Ref . + +Instance = .