This is a series of examples showing capabilities in action using
If you are not familiar with capabilities, please read through the guide for a more in-depth explanation.
All the examples given rely on the following imports:
import ocaps._ import ocaps.macros._
This section shows creation of capabilities and direct use.
This section shows structural patterns that do not change behavior.
This section shows patterns that change the behavior of capabilities, typically adding side effects or blocking execution completely.
This section shows capabilities used together#.
This section shows capabilities in the context of authorization and delegation.
This section shows capabilities being rendered inaccessible or made accessible through a membrane.