Open Semantic Framework PHP API  3.0
 All Data Structures Namespaces Files Functions Variables Pages
RevisionDiffQuery Class Reference

Revision Diff Query to a OSF Revision Diff web service endpoint. More...

Inheritance diagram for RevisionDiffQuery:

Public Member Functions

 __construct ($network, $appID, $apiKey, $userID)
 Constructor. More...
 
 leftRevisionUri ($uri)
 Specifies the first revision URI to compare. More...
 
 rightRevisionUri ($uri)
 Specifies the second revision URI to compare. More...
 
 dataset ($dataset)
 Specifies the dataset URI where the record is indexed. More...
 

Detailed Description

Revision Diff Query to a OSF Revision Diff web service endpoint.

The Revision: Diff web service endpoint is used to compare two revisions of the same record. A ChangeSet which contains all the added and removed triples between the two revisions is returned.

Here is a code example of how this class can be used by developers:

// Use the RevisionDiffQuery class
use \StructuredDynamics\osf\php\api\ws\revision\diff\RevisionDiffQuery;
// Create the RevisionDiffQuery object
$revisiondiff = new RevisionDiffQuery("http://demo.citizen-dan.org/ws/");
$revisiondiff->leftRecordUri('http://demo.citizen-dan.org/datasets/test/1/revision/12335.123');
$revisiondiff->rightRecordUri('http://demo.citizen-dan.org/datasets/test/1/revision/52312.346');
$revisiondiff->dataset('http://demo.citizen-dan.org/datasets/test/');
// Send the revision diff query to the endpoint
$revisiondiff->send();
// Get back the resultset returned by the endpoint
$resultset = $revisiondiff->getResultset();
// Print different serializations for that resultset
print_r($resultset->getResultset());
See also
http://wiki.opensemanticframework.org/index.php/Revision:_Diff
Author
Frederick Giasson, Structured Dynamics LLC.

Definition at line 50 of file RevisionDiffQuery.php.

Constructor & Destructor Documentation

__construct (   $network,
  $appID,
  $apiKey,
  $userID 
)

Constructor.

Parameters
mixed$networkOSF network where to send this query. Ex: http://localhost/ws/
mixed$appIDThe Application ID of the instance instance to key. The APP-ID is related to the API-KEY
mixed$apiKeyThe API Key of the OSF web service endpoints
mixed$userIDThe ID of the user that is doing the query

Definition at line 60 of file RevisionDiffQuery.php.

Member Function Documentation

dataset (   $dataset)

Specifies the dataset URI where the record is indexed.

Parameters
$datasetThe dataset URI where the record is indexed. This is the URI of the dataset, and not the URI of the revisions dataset.
See also
http://wiki.opensemanticframework.org/index.php/Revision:_Diff#Web_Service_Endpoint_Information
Author
Frederick Giasson, Structured Dynamics LLC.

Definition at line 129 of file RevisionDiffQuery.php.

leftRevisionUri (   $uri)

Specifies the first revision URI to compare.

Parameters
$uriFirst revision URI to compare.
See also
http://wiki.opensemanticframework.org/index.php/Revision:_Diff#Web_Service_Endpoint_Information
Author
Frederick Giasson, Structured Dynamics LLC.*

Definition at line 95 of file RevisionDiffQuery.php.

rightRevisionUri (   $uri)

Specifies the second revision URI to compare.

Parameters
$uriSecond revision URI to compare.
See also
http://wiki.opensemanticframework.org/index.php/Revision:_Diff#Web_Service_Endpoint_Information
Author
Frederick Giasson, Structured Dynamics LLC.*

Definition at line 112 of file RevisionDiffQuery.php.