How To Install php-easyrdf on Ubuntu 20.04
Introduction
In this tutorial we learn how to install php-easyrdf
on Ubuntu 20.04.
What is php-easyrdf
php-easyrdf is:
EasyRdf is a PHP library to consume and produce RDF. Resource Description Framework, RDF, is an official W3C Recommendation for Semantic Web data models.
After parsing EasyRdf builds up a graph of PHP objects that can then be walked around to get the data to be placed on the page. Dump methods are available to inspect what data is available during development.
Data is typically loaded into a EasyRdf_Graph object from source RDF documents, loaded from the web via HTTP. The EasyRdf_GraphStore class can load and save data on a SPARQL 1.1 Graph Store.
SPARQL queries can be made over HTTP to a Triplestore using the EasyRdf_Sparql_Client class. SELECT and ASK queries will return an EasyRdf_Sparql_Result object and CONSTRUCT and DESCRIBE queries will return an EasyRdf_Graph object.
There are three methods to install php-easyrdf
on Ubuntu 20.04. We can use apt-get
, apt
and aptitude
. In the following sections we will describe each method. You can choose one of them.
Install php-easyrdf Using apt-get
Update apt database with apt-get
using the following command.
sudo apt-get update
After updating apt database, We can install php-easyrdf
using apt-get
by running the following command:
sudo apt-get -y install php-easyrdf
Install php-easyrdf Using apt
Update apt database with apt
using the following command.
sudo apt update
After updating apt database, We can install php-easyrdf
using apt
by running the following command:
sudo apt -y install php-easyrdf
Install php-easyrdf Using aptitude
If you want to follow this method, you might need to install aptitude first since aptitude is usually not installed by default on Ubuntu. Update apt database with aptitude
using the following command.
sudo aptitude update
After updating apt database, We can install php-easyrdf
using aptitude
by running the following command:
sudo aptitude -y install php-easyrdf
How To Uninstall php-easyrdf on Ubuntu 20.04
To uninstall only the php-easyrdf
package we can use the following command:
sudo apt-get remove php-easyrdf
Uninstall php-easyrdf And Its Dependencies
To uninstall php-easyrdf
and its dependencies that are no longer needed by Ubuntu 20.04, we can use the command below:
sudo apt-get -y autoremove php-easyrdf
Remove php-easyrdf Configurations and Data
To remove php-easyrdf
configuration and data from Ubuntu 20.04 we can use the following command:
sudo apt-get -y purge php-easyrdf
Remove php-easyrdf configuration, data, and all of its dependencies
We can use the following command to remove php-easyrdf
configurations, data and all of its dependencies, we can use the following command:
sudo apt-get -y autoremove --purge php-easyrdf
References
Summary
In this tutorial we learn how to install php-easyrdf
package on Ubuntu 20.04 using different package management tools: apt
, apt-get
and aptitude
.