| Rasqal RDF Query Library Manual | ||||
|---|---|---|---|---|
| Top | Description | ||||
rasqal_prefix; rasqal_prefix* rasqal_new_prefix (rasqal_world *world,unsigned char *prefix,raptor_uri *uri); void rasqal_free_prefix (rasqal_prefix *p); int rasqal_prefix_print (rasqal_prefix *p,FILE *fh);
Used inside a rasqal_query to declare syntax prefix abbreviations for URIs. Once a rasqal_query is constructed, these are for information only.
typedef struct {
rasqal_world* world;
const unsigned char *prefix;
raptor_uri* uri;
int declared;
int depth;
} rasqal_prefix;
Namespace (prefix, uri) pair.
Includes internal flags used for marking when prefixes are declared and at what XML element depth when used in XML formats.
rasqal_world * |
rasqal_world object |
raptor_uri * |
URI associated with the prefix. |
| Internal flag. | |
| Internal flag. |
rasqal_prefix* rasqal_new_prefix (rasqal_world *world,unsigned char *prefix,raptor_uri *uri);
Constructor - create a new rasqal_prefix. Takes ownership of prefix and uri.
|
rasqal_world object |
|
Short prefix string to stand for URI (or NULL) |
|
Name raptor_uri. |
Returns : |
a new rasqal_prefix or NULL on failure. |
void rasqal_free_prefix (rasqal_prefix *p);
Destructor - destroy a rasqal_prefix object.
|
rasqal_prefix object. |
int rasqal_prefix_print (rasqal_prefix *p,FILE *fh);
Print a Rasqal prefix in a debug format.
The print debug format may change in any release.
|
rasqal_prefix object. |
|
The FILE* handle to print to. |
Returns : |
non-0 on failure |