| Rasqal RDF Query Library Manual | ||||
|---|---|---|---|---|
| Top | Description | ||||
typedef rasqal_service; rasqal_service* rasqal_new_service (rasqal_world *world,raptor_uri *service_uri,const char *query_string,raptor_sequence *data_graphs); void rasqal_free_service (rasqal_service *svc); rasqal_query_results* rasqal_service_execute (rasqal_service *svc); int rasqal_service_set_format (rasqal_service *svc,const char *format); int rasqal_service_set_www (rasqal_service *svc,raptor_www *www);
The SPARQL Protocol defines an HTTP binding that enables remote queries to be executed over specified default and named graphs. This class allows that to be constructed and executed, returning a Rasqal query results rasqal_query_results that may be used, for example, with a formatter to generate output.
rasqal_service* rasqal_new_service (rasqal_world *world,raptor_uri *service_uri,const char *query_string,raptor_sequence *data_graphs);
Constructor - create a new rasqal protocol service object.
Create a structure to execute a sparql protocol service at
service_uri running the query query_string and returning
a sparql result set.
All arguments are copied by the service object
|
rasqal_world object |
|
sparql protocol service URI |
|
query string (or NULL) |
|
sequence of rasqal_data_graph graphs for service |
Returns : |
a new rasqal_query object or NULL on failure |
void rasqal_free_service (rasqal_service *svc);
Destructor - destroy a rasqal_service object.
|
rasqal_service object |
rasqal_query_results* rasqal_service_execute (rasqal_service *svc);
Execute a rasqal sparql protocol service
|
rasqal service |
Returns : |
query results or NULL on failure |
int rasqal_service_set_format (rasqal_service *svc,const char *format);
Set the MIME Type to use in HTTP Accept when executing the service
|
rasqal_service service object |
|
service mime type (or NULL) |
Returns : |
non 0 on failure |
int rasqal_service_set_www (rasqal_service *svc,raptor_www *www);
Set the WWW object to use when executing the service
|
rasqal_service service object |
|
WWW object (or NULL) |
Returns : |
non 0 on failure |