<?xml version='1.0'?>

<!-- CardinalityQIndication - minCardinalityQ -->

<rdf:RDF
  xmlns:rdf ="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
  xmlns:rdfs="http://www.w3.org/2000/01/rdf-schema#"
  xmlns:xsd ="http://www.w3.org/2000/10/XMLSchema#"
  xmlns:daml="http://www.daml.org/2001/03/daml+oil#"
  xmlns:ont1="http://www.daml.org/validator/examples/ont1.daml#"
  xmlns:ont2="http://www.daml.org/validator/examples/ont2.daml#"
  xmlns:dt1 ="http://www.daml.org/validator/examples/dt1.xsd#"
  xmlns     ="http://www.daml.org/validator/examples/in11.daml#"
>

<!-- A ont2:SuperAthlete is an athlete who lists 3 or more ont2:SportsHobby as ont2:hasHobby -->

<!-- OK - Has three sports hobbies -->
<ont2:SuperAthlete rdf:ID="sean">
  <ont2:hasHobby rdf:resource="http://www.daml.org/validator/examples/ont2.daml#soccer"/>
  <ont2:hasHobby rdf:resource="http://www.daml.org/validator/examples/ont2.daml#football"/>
  <ont2:hasHobby rdf:resource="http://www.daml.org/validator/examples/ont2.daml#baseball"/>
</ont2:SuperAthlete>

<!-- OK - has more than three sports hobbies -->
<ont2:SuperAthlete rdf:ID="roger">
  <ont2:hasHobby rdf:resource="http://www.daml.org/validator/examples/ont2.daml#soccer"/>
  <ont2:hasHobby rdf:resource="http://www.daml.org/validator/examples/ont2.daml#football"/>
  <ont2:hasHobby rdf:resource="http://www.daml.org/validator/examples/ont2.daml#baseball"/>
  <ont2:hasHobby rdf:resource="http://www.daml.org/validator/examples/ont2.daml#tennis"/>
  <ont2:hasHobby rdf:resource="http://www.daml.org/validator/examples/ont2.daml#guitar"/>
  <ont2:hasHobby rdf:resource="http://www.daml.org/validator/examples/ont2.daml#rockclimbing"/>
  <ont2:hasHobby rdf:resource="http://www.daml.org/validator/examples/ont2.daml#piano"/>
</ont2:SuperAthlete>


<!-- ERROR - Has less than three sports hobbies -->
<ont2:SuperAthlete rdf:ID="pierce">
  <ont2:hasHobby rdf:resource="http://www.daml.org/validator/examples/ont2.daml#soccer"/>
  <ont2:hasHobby rdf:resource="http://www.daml.org/validator/examples/ont2.daml#football"/>
  <ont2:hasHobby rdf:resource="http://www.daml.org/validator/examples/ont2.daml#violin"/>
  <ont2:hasHobby rdf:resource="http://www.daml.org/validator/examples/ont2.daml#singing"/>
  <ont2:hasHobby rdf:resource="http://www.daml.org/validator/examples/ont2.daml#piano"/>
</ont2:SuperAthlete>

<!-- ERROR - has no sports or other hobbies -->
<ont2:SuperAthlete rdf:ID="timothy">
</ont2:SuperAthlete>

<!-- You can also declare other instances SuperAthletes (from in in5.daml) -->

<!-- OK - stan has three sports hobbies -->
<ont2:SuperAthlete rdf:about="http://www.daml.org/validator/examples/in5.daml#stan"/>

<!-- ERROR - kyle only has one sport -->
<ont2:SuperAthlete rdf:about="http://www.daml.org/validator/examples/in5.daml#kyle"/>

</rdf:RDF>
