-
Notifications
You must be signed in to change notification settings - Fork 1
Turtle Examples for Module 2
Exercise Open any text editor. Using Turtle create both the most verbose and terse set of triples for the following information: “Steven is facilitating this workshop, and you and a colleague are participants.”
_:Steven _:facilitatorOf _:LD4Workshop2020 .
_:You _:attended _:LD4Workshop2020 .
_:AColleague _:attended _:LD4Workshop2020 .
Note that each assertion is a separate stand alone triple. Also, the same node is used for the workshop. The same property is used for 'attending', and a separate property for 'facilitating'.
_:LD4Workshop2020 _:hasFacilitator _:Steven ; _:hasAttendee _:You , _:AColleague .
In this example, we see multiple built-in Turtle syntax abbreviations in use. There is one subject (:LD4Workshop2020) that never repeats. Instead, after asserting the facilitator (_:hasFacilitator _:Steven) we can continue to make assertions about the workshop by switching properties using a semicolon. Notice also how :hasAttendee has multiple values (:You , _:AColleague) using the comma.