protected function EasyRdf_Parser_Rdfa::addTriple

Add a triple to the current graph, and keep count of the number of triples @ignore

Overrides EasyRdf_Parser::addTriple

2 calls to EasyRdf_Parser_Rdfa::addTriple()
EasyRdf_Parser_Rdfa::generateList in drupal/core/vendor/easyrdf/easyrdf/lib/EasyRdf/Parser/Rdfa.php
EasyRdf_Parser_Rdfa::processNode in drupal/core/vendor/easyrdf/easyrdf/lib/EasyRdf/Parser/Rdfa.php

File

drupal/core/vendor/easyrdf/easyrdf/lib/EasyRdf/Parser/Rdfa.php, line 67

Class

EasyRdf_Parser_Rdfa
Class to parse RDFa 1.1 with no external dependancies.

Code

protected function addTriple($resource, $property, $value) {
  if ($this->debug) {
    print "Adding triple: {$resource} -> {$property} -> " . $value['type'] . ':' . $value['value'] . "\n";
  }
  $count = $this->graph
    ->add($resource, $property, $value);
  $this->tripleCount += $count;
  return $count;
}