public function EasyRdf_Resource::set in Zircon Profile 8.0
Same name and namespace in other branches
- 8 vendor/easyrdf/easyrdf/lib/EasyRdf/Resource.php \EasyRdf_Resource::set()
Set value for a property
The new value(s) will replace the existing values for the property. The name of the property should be a string. If you set a property to null or an empty array, then the property will be deleted.
Parameters
string $property The name of the property (e.g. foaf:name):
mixed $value The value for the property.:
Return value
integer The number of values added (1 or 0)
1 call to EasyRdf_Resource::set()
- EasyRdf_Container::offsetSet in vendor/
easyrdf/ easyrdf/ lib/ EasyRdf/ Container.php - Array Access: set an item at a positon in container using array syntax
File
- vendor/
easyrdf/ easyrdf/ lib/ EasyRdf/ Resource.php, line 341
Class
- EasyRdf_Resource
- Class that represents an RDF resource
Code
public function set($property, $value) {
$this
->checkHasGraph();
return $this->graph
->set($this->uri, $property, $value);
}