diff --git a/documentation/constrained-containers.md b/documentation/constrained-containers.md index 2269cb9..5270ced 100644 --- a/documentation/constrained-containers.md +++ b/documentation/constrained-containers.md @@ -1,8 +1,8 @@ # Constrained containers In CSS, it is possible to have containers where all its resources conform to a given [SHACL](https://www.w3.org/TR/shacl/) shape. -Providing shape validation ensures that applications can then rely on the fact that -the structure of the graph in the resources are valid. +Providing shape validation ensures that applications can then rely on the fact that +the structure of the graph in the resources is valid. ## Constrained containers in practice @@ -12,7 +12,7 @@ A container can be made shape constrained by editing its description resource. A triple of the form `?container ldp:constrainedBy ?shape .` must be added, where `?container` is the URL of the container being made constrained and `?shape` is the URL of the SHACL shape. -A precondition for making a container constrained is that the container must not contain any resource at initialisation of making it shape constrained. +A precondition for making a container constrained is that the container must not contain any resources. Furthermore, it is only possible to initialise one shape resource per container. ### Discovery of a constrained container @@ -22,12 +22,12 @@ with `"rel"` `http://www.w3.org/ns/ldp#constrainedBy` as is defined in [LDP](htt ## Impact of constraining a container -Only resources can be created that conform to the constraints on a constrained container. +Only resources can be created that conform to the constraints of a constrained container. However, some additional restrictions are enforced by the server on that container: * It is not possible to add any non-RDF resources. * Creating containers within this constrained container is not allowed. -* Requests that results into a resource where no targetClasses from the shape are present are prohibited and will thus produce an error. +* Requests that result in a resource where no `sh:targetClasses` from the shape are present are prohibited and will thus produce an error. ## Example of a workflow on how to constrain a container @@ -47,7 +47,7 @@ solid:inserts { ; rel="http://www.w3.org/ns/ldp#constrainedBy" ``` -The container is now indeed constrained by the shape. -This means that all the resources that will be added in this container are conform to the shape. +The container is now indeed constrained by the shape. +This means that all the resources that will be added to this container conform to the shape. -In this example, we used a SHACL shape that was stored on the server. +In this example, we used a SHACL shape that was stored on the server. However, we can use any SHACL shape that can be fetched on the web via HTTP.