Resource Class Reference
Interact with the triple store to get information about a specific resource. More...
Public Member Functions | |
| __construct ($uri, $dataset, $includeLinkbacks) | |
| Constructor. | |
| __destruct () | |
| getTypes () | |
| Get the types describing this resource. | |
| getDataset () | |
| Get the dataset where the resource has been indexed. | |
| getSubjectProperties () | |
| Get the properties where the resource is a subject. | |
| getObjectProperties () | |
| Get the properties where the resource is a object. | |
| getPropertyValues ($property) | |
| Get the values for a given property describing the resource. | |
| getLabel () | |
| Get a label for that resource. | |
| getLabels () | |
| Get labels for that resource. | |
| getReificationStatements () | |
| getRawSerialization () | |
| Raw data (text/xml) describing the resource. This is normally used to feed another module/template with the raw description of the resource. | |
| getURI () | |
Public Attributes | |
| $subjectTriples = array() | |
| Array of triples where the current resource is a subject. | |
| $objectTriples = array() | |
| Array of triples where the current resource is an object. | |
| $reificationTriples = array() | |
| Array of triples that reify triples of a resource description. | |
| $rawSerialization = array() | |
| Raw data (text/xml) describing the resource. This is normally used to feed another module/template with the raw description of the resource. | |
Private Attributes | |
| $uri = "" | |
| URI of the current resource. | |
| $dataset = "" | |
| URI of the dataset where the resource is indexed. | |
Detailed Description
Interact with the triple store to get information about a specific resource.
Definition at line 26 of file Resource.php.
Constructor & Destructor Documentation
| Resource::__construct | ( | $ | uri, | |
| $ | dataset, | |||
| $ | includeLinkbacks | |||
| ) |
Constructor.
- Parameters:
-
[in] $uri URI of the resource being defined [in] $dataset URI of the dataset where to get the description of the resource. This parameter can be an empty string. If it is, the system will try to find the dataset URI from the resource URI. [in] $includeLinkbacks Tells the system if we include the object-triples (queries take longer to resolve)
Definition at line 59 of file Resource.php.
References $base_url, $dataset, $uri, $userIP, $wsq, getDatasetFromUri(), and getGroupIdFromDatasetUri().

| Resource::__destruct | ( | ) |
Definition at line 281 of file Resource.php.
Member Function Documentation
| Resource::getDataset | ( | ) |
Get the dataset where the resource has been indexed.
- Returns:
- returns the URI of the dataset where the resource has been indexed
Definition at line 317 of file Resource.php.
| Resource::getLabel | ( | ) |
Get a label for that resource.
- Returns:
- returns Returns a literal that can be used as a label for that resource
Definition at line 401 of file Resource.php.
References Namespaces::$dcterms, Namespaces::$doap, Namespaces::$foaf, Namespaces::$geoname, Namespaces::$iron, Namespaces::$rdfs, Namespaces::$skos_2004, and Namespaces::$skos_2008.
| Resource::getLabels | ( | ) |
Get labels for that resource.
- Returns:
- returns Returns an array of literals that can be used as a label for that resource
Definition at line 452 of file Resource.php.
References Namespaces::$dcterms, Namespaces::$doap, Namespaces::$foaf, Namespaces::$geoname, Namespaces::$iron, Namespaces::$rdfs, Namespaces::$skos_2004, and Namespaces::$skos_2008.
| Resource::getObjectProperties | ( | ) |
Get the properties where the resource is a object.
- Returns:
- returns an array properties
Definition at line 354 of file Resource.php.
| Resource::getPropertyValues | ( | $ | property | ) |
Get the values for a given property describing the resource.
- Returns:
- returns an array of values for a given property
Definition at line 376 of file Resource.php.
| Resource::getRawSerialization | ( | ) |
Raw data (text/xml) describing the resource. This is normally used to feed another module/template with the raw description of the resource.
- Returns:
- returns Returns a string with the raw text/xml description data of the resource.
Definition at line 499 of file Resource.php.
| Resource::getReificationStatements | ( | ) |
Definition at line 483 of file Resource.php.
| Resource::getSubjectProperties | ( | ) |
Get the properties where the resource is a subject.
- Returns:
- returns an array properties
Definition at line 332 of file Resource.php.
| Resource::getTypes | ( | ) |
Get the types describing this resource.
- Returns:
- returns an array of URIs of types for this resource. An empty array of no types exists for this resource.
Definition at line 294 of file Resource.php.
| Resource::getURI | ( | ) |
Definition at line 504 of file Resource.php.
Member Data Documentation
Resource::$dataset = "" [private] |
URI of the dataset where the resource is indexed.
Definition at line 38 of file Resource.php.
Referenced by __construct().
| Resource::$objectTriples = array() |
Array of triples where the current resource is an object.
Definition at line 32 of file Resource.php.
| Resource::$rawSerialization = array() |
Raw data (text/xml) describing the resource. This is normally used to feed another module/template with the raw description of the resource.
Definition at line 45 of file Resource.php.
| Resource::$reificationTriples = array() |
Array of triples that reify triples of a resource description.
Definition at line 41 of file Resource.php.
| Resource::$subjectTriples = array() |
Array of triples where the current resource is a subject.
Definition at line 29 of file Resource.php.
Resource::$uri = "" [private] |
URI of the current resource.
Definition at line 35 of file Resource.php.
Referenced by __construct().
The documentation for this class was generated from the following file:
