Lines Matching defs:graph
119 function removeTriples($subject=null, $predicate=null, $object=null, $graph=null) {
122 foreach(array('subject','predicate','object','graph') as $param) {
149 function fetchTriples($subject=null, $predicate=null, $object=null, $graph=null) {
154 foreach(array('subject','predicate','object','graph') as $param) {
161 $scopeRestriction = ($this->getConf('scoped')? ' AND graph like "'.getNS($ID).'%"':"" );
167 { $scopeRestriction = "and graph not like '%:%'"; }
170 { $scopeRestriction = "and graph like".$NS.":%"; }
176 $sql = "SELECT subject, predicate, object, graph FROM ".self::$readable." WHERE ". implode(" AND ", $filters).$scopeRestriction;
202 * @param graph string
205 function addTriple($subject, $predicate, $object, $graph) {
206 return $this->addTriples(array(array('subject'=>$subject, 'predicate'=>$predicate, 'object'=>$object)), $graph);
212 * @param graph string graph name
215 function addTriples($triples, $graph) {
217 $sql = "INSERT INTO ".self::$writable."(subject, predicate, object, graph) VALUES(?, ?, ?, ?)";
225 $values = array($t['subject'],$t['predicate'],$t['object'],$graph);
495 * Translates a triple pattern into a graph pattern.
516 $scopeRestriction = ($this->_triples->getConf('scoped')? ' AND graph like "'.getNS($ID).'%"':"" );
524 * Translates a group operation on the two graph patterns.
682 // dispatch the child graph patterns