Replies: 2 comments 1 reply
-
That looks excellent, but we should probably have the documentation follow the same approach as other elements of a schema. { "@type" : "Constraint",
"@id": "MyExampleContraint",
"@documentation":[
{"@comment":"An example constraint which does something special",
"@label":"Example Constraint",
"@language":"en" },
{"@comment":"მაგალითი კლასი",
"@label":"მაგალითი",
"@language":"ka"} ]
...} |
Beta Was this translation helpful? Give feedback.
0 replies
-
@matko Could you please edit original post with added |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
We should have the ability to specify constraints that are more advanced than what we now get out of the basic types.
Here's some rough notes with proposed syntax.
This gets unwieldy with more constraints though!
So anonymous constraints could be good, but the moment we have more than one constraint it can be good to split them out, give us an opportunity to document them too.
In all these cases we put the constraint on Policy, but some of these constraints actually matched over a bunch of related instances using the
@match
word. One could imagine a kind of constraint that is actually not linked to any particular type.From prototyping this it kinda looks like
@on
is just a way to shortcut, so that we have a default context to match things in. But you could always match an arbitrary type just with@match
.It does kind of seem like this is a partial re-invention of woql. The main difference here is that this is meant to express constraints only. So no mutations of any kind, no transformation of results into fancy documents, just link following and constraints after following those links.
Beta Was this translation helpful? Give feedback.
All reactions