/**
  * Adds specific value
  *
  * @param RdfWriter $writer
  * @param string $propertyValueNamespace Property value relation namespace
  * @param string $propertyValueLName Property value relation name
  * @param string $dataType Property data type
  * @param PropertyValueSnak $snak
  */
 public function addValue(RdfWriter $writer, $propertyValueNamespace, $propertyValueLName, $dataType, PropertyValueSnak $snak)
 {
     $value = $snak->getDataValue();
     $entityId = $value->getValue()->getEntityId();
     $entityLName = $this->vocabulary->getEntityLName($entityId);
     $writer->say($propertyValueNamespace, $propertyValueLName)->is(RdfVocabulary::NS_ENTITY, $entityLName);
     $this->mentionedEntityTracker->entityReferenceMentioned($entityId);
 }
 /**
  * Adds the given Statement's main Snak to the RDF graph.
  *
  * @param RdfWriter $writer
  * @param Snak $snak
  * @param string $propertyNamespace
  *
  * @throws InvalidArgumentException
  */
 public function addSnak(RdfWriter $writer, Snak $snak, $propertyNamespace)
 {
     $propertyId = $snak->getPropertyId();
     switch ($snak->getType()) {
         case 'value':
             /** @var PropertyValueSnak $snak */
             $this->addSnakValue($writer, $snak, $propertyNamespace);
             break;
         case 'somevalue':
             $propertyValueLName = $this->vocabulary->getEntityLName($propertyId);
             $writer->say($propertyNamespace, $propertyValueLName)->is('_', $writer->blank());
             break;
         case 'novalue':
             $propertyValueLName = $this->vocabulary->getEntityLName($propertyId);
             $writer->say('a')->is(RdfVocabulary::NSP_NOVALUE, $propertyValueLName);
             break;
         default:
             throw new InvalidArgumentException('Unknown snak type: ' . $snak->getType());
     }
     $this->mentionedEntityTracker->propertyMentioned($snak->getPropertyId());
 }