You are here

public function EasyRdf_Graph::countValues in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 vendor/easyrdf/easyrdf/lib/EasyRdf/Graph.php \EasyRdf_Graph::countValues()

Count the number of values for a property of a resource

Parameters

string $resource The URI of the resource (e.g. http://example.com/joe#me):

string $property The name of the property (e.g. foaf:name):

string $type The type of value to filter by (e.g. literal):

string $lang The language to filter by (e.g. en):

Return value

integer The number of values for this property

File

vendor/easyrdf/easyrdf/lib/EasyRdf/Graph.php, line 885

Class

EasyRdf_Graph
Container for collection of EasyRdf_Resources.

Code

public function countValues($resource, $property, $type = null, $lang = null) {
  return count($this
    ->all($resource, $property, $type, $lang));
}