| 1 | <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> |
| 2 | <html> |
| 3 | <head> |
| 4 | <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> |
| 5 | <title>Triple stores</title> |
| 6 | <meta name="generator" content="DocBook XSL Stylesheets V1.76.1"> |
| 7 | <link rel="home" href="index.html" title="Redland RDF Library Manual"> |
| 8 | <link rel="up" href="reference-manual.html" title="Part II. Reference Manual"> |
| 9 | <link rel="prev" href="redland-statement.html" title="RDF Triple (librdf_statement)"> |
| 10 | <link rel="next" href="redland-storage-modules.html" title="Storage Modules"> |
| 11 | <meta name="generator" content="GTK-Doc V1.18 (XML mode)"> |
| 12 | <link rel="stylesheet" href="style.css" type="text/css"> |
| 13 | </head> |
| 14 | <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"> |
| 15 | <table class="navigation" id="top" width="100%" summary="Navigation header" cellpadding="2" cellspacing="2"> |
| 16 | <tr valign="middle"> |
| 17 | <td><a accesskey="p" href="redland-statement.html"><img src="left.png" width="24" height="24" border="0" alt="Prev"></a></td> |
| 18 | <td><a accesskey="u" href="reference-manual.html"><img src="up.png" width="24" height="24" border="0" alt="Up"></a></td> |
| 19 | <td><a accesskey="h" href="index.html"><img src="home.png" width="24" height="24" border="0" alt="Home"></a></td> |
| 20 | <th width="100%" align="center">Redland RDF Library Manual</th> |
| 21 | <td><a accesskey="n" href="redland-storage-modules.html"><img src="right.png" width="24" height="24" border="0" alt="Next"></a></td> |
| 22 | </tr> |
| 23 | <tr><td colspan="5" class="shortcuts"> |
| 24 | <a href="#redland-storage.synopsis" class="shortcut">Top</a> |
| 25 | | |
| 26 | <a href="#redland-storage.description" class="shortcut">Description</a> |
| 27 | </td></tr> |
| 28 | </table> |
| 29 | <div class="refentry"> |
| 30 | <a name="redland-storage"></a><div class="titlepage"></div> |
| 31 | <div class="refnamediv"><table width="100%"><tr> |
| 32 | <td valign="top"> |
| 33 | <h2><span class="refentrytitle"><a name="redland-storage.top_of_page"></a>Triple stores</span></h2> |
| 34 | <p>Triple stores — RDF Triple stores</p> |
| 35 | </td> |
| 36 | <td valign="top" align="right"></td> |
| 37 | </tr></table></div> |
| 38 | <div class="refsynopsisdiv"> |
| 39 | <a name="redland-storage.synopsis"></a><h2>Synopsis</h2> |
| 40 | <pre class="synopsis">#define <a class="link" href="redland-storage.html#LIBRDF-STORAGE-INTERFACE-VERSION:CAPS" title="LIBRDF_STORAGE_INTERFACE_VERSION">LIBRDF_STORAGE_INTERFACE_VERSION</a> |
| 41 | #define <a class="link" href="redland-storage.html#LIBRDF-STORAGE-MAX-INTERFACE-VERSION:CAPS" title="LIBRDF_STORAGE_MAX_INTERFACE_VERSION">LIBRDF_STORAGE_MAX_INTERFACE_VERSION</a> |
| 42 | #define <a class="link" href="redland-storage.html#LIBRDF-STORAGE-MIN-INTERFACE-VERSION:CAPS" title="LIBRDF_STORAGE_MIN_INTERFACE_VERSION">LIBRDF_STORAGE_MIN_INTERFACE_VERSION</a> |
| 43 | typedef <a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage">librdf_storage</a>; |
| 44 | typedef <a class="link" href="redland-storage.html#librdf-storage-factory" title="librdf_storage_factory">librdf_storage_factory</a>; |
| 45 | <span class="returnvalue">int</span> <a class="link" href="redland-storage.html#librdf-storage-register-factory" title="librdf_storage_register_factory ()">librdf_storage_register_factory</a> (<em class="parameter"><code><a class="link" href="redland-world.html#librdf-world" title="librdf_world"><span class="type">librdf_world</span></a> *world</code></em>, |
| 46 | <em class="parameter"><code>const <span class="type">char</span> *name</code></em>, |
| 47 | <em class="parameter"><code>const <span class="type">char</span> *label</code></em>, |
| 48 | <em class="parameter"><code><span class="type">void</span> (*factory) (librdf_storage_factory*)</code></em>); |
| 49 | <span class="returnvalue">int</span> <a class="link" href="redland-storage.html#librdf-storage-enumerate" title="librdf_storage_enumerate ()">librdf_storage_enumerate</a> (<em class="parameter"><code><a class="link" href="redland-world.html#librdf-world" title="librdf_world"><span class="type">librdf_world</span></a> *world</code></em>, |
| 50 | <em class="parameter"><code>const unsigned <span class="type">int</span> counter</code></em>, |
| 51 | <em class="parameter"><code>const <span class="type">char</span> **name</code></em>, |
| 52 | <em class="parameter"><code>const <span class="type">char</span> **label</code></em>); |
| 53 | <a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="returnvalue">librdf_storage</span></a> * <a class="link" href="redland-storage.html#librdf-new-storage" title="librdf_new_storage ()">librdf_new_storage</a> (<em class="parameter"><code><a class="link" href="redland-world.html#librdf-world" title="librdf_world"><span class="type">librdf_world</span></a> *world</code></em>, |
| 54 | <em class="parameter"><code>const <span class="type">char</span> *storage_name</code></em>, |
| 55 | <em class="parameter"><code>const <span class="type">char</span> *name</code></em>, |
| 56 | <em class="parameter"><code>const <span class="type">char</span> *options_string</code></em>); |
| 57 | <a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="returnvalue">librdf_storage</span></a> * <a class="link" href="redland-storage.html#librdf-new-storage-with-options" title="librdf_new_storage_with_options ()">librdf_new_storage_with_options</a> (<em class="parameter"><code><a class="link" href="redland-world.html#librdf-world" title="librdf_world"><span class="type">librdf_world</span></a> *world</code></em>, |
| 58 | <em class="parameter"><code>const <span class="type">char</span> *storage_name</code></em>, |
| 59 | <em class="parameter"><code>const <span class="type">char</span> *name</code></em>, |
| 60 | <em class="parameter"><code><a class="link" href="redland-hash.html#librdf-hash" title="librdf_hash"><span class="type">librdf_hash</span></a> *options</code></em>); |
| 61 | <a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="returnvalue">librdf_storage</span></a> * <a class="link" href="redland-storage.html#librdf-new-storage-from-storage" title="librdf_new_storage_from_storage ()">librdf_new_storage_from_storage</a> (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *old_storage</code></em>); |
| 62 | <a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="returnvalue">librdf_storage</span></a> * <a class="link" href="redland-storage.html#librdf-new-storage-from-factory" title="librdf_new_storage_from_factory ()">librdf_new_storage_from_factory</a> (<em class="parameter"><code><a class="link" href="redland-world.html#librdf-world" title="librdf_world"><span class="type">librdf_world</span></a> *world</code></em>, |
| 63 | <em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage-factory" title="librdf_storage_factory"><span class="type">librdf_storage_factory</span></a> *factory</code></em>, |
| 64 | <em class="parameter"><code>const <span class="type">char</span> *name</code></em>, |
| 65 | <em class="parameter"><code><a class="link" href="redland-hash.html#librdf-hash" title="librdf_hash"><span class="type">librdf_hash</span></a> *options</code></em>); |
| 66 | <span class="returnvalue">void</span> <a class="link" href="redland-storage.html#librdf-free-storage" title="librdf_free_storage ()">librdf_free_storage</a> (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>); |
| 67 | <span class="returnvalue">int</span> <a class="link" href="redland-storage.html#librdf-storage-open" title="librdf_storage_open ()">librdf_storage_open</a> (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>, |
| 68 | <em class="parameter"><code><a class="link" href="redland-model.html#librdf-model" title="librdf_model"><span class="type">librdf_model</span></a> *model</code></em>); |
| 69 | <span class="returnvalue">int</span> <a class="link" href="redland-storage.html#librdf-storage-close" title="librdf_storage_close ()">librdf_storage_close</a> (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>); |
| 70 | <span class="returnvalue">int</span> <a class="link" href="redland-storage.html#librdf-storage-size" title="librdf_storage_size ()">librdf_storage_size</a> (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>); |
| 71 | <span class="returnvalue">int</span> <a class="link" href="redland-storage.html#librdf-storage-add-statement" title="librdf_storage_add_statement ()">librdf_storage_add_statement</a> (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>, |
| 72 | <em class="parameter"><code><a class="link" href="redland-statement.html#librdf-statement" title="librdf_statement"><span class="type">librdf_statement</span></a> *statement</code></em>); |
| 73 | <span class="returnvalue">int</span> <a class="link" href="redland-storage.html#librdf-storage-add-statements" title="librdf_storage_add_statements ()">librdf_storage_add_statements</a> (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>, |
| 74 | <em class="parameter"><code><a class="link" href="redland-stream.html#librdf-stream" title="librdf_stream"><span class="type">librdf_stream</span></a> *statement_stream</code></em>); |
| 75 | <span class="returnvalue">int</span> <a class="link" href="redland-storage.html#librdf-storage-remove-statement" title="librdf_storage_remove_statement ()">librdf_storage_remove_statement</a> (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>, |
| 76 | <em class="parameter"><code><a class="link" href="redland-statement.html#librdf-statement" title="librdf_statement"><span class="type">librdf_statement</span></a> *statement</code></em>); |
| 77 | <span class="returnvalue">int</span> <a class="link" href="redland-storage.html#librdf-storage-contains-statement" title="librdf_storage_contains_statement ()">librdf_storage_contains_statement</a> (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>, |
| 78 | <em class="parameter"><code><a class="link" href="redland-statement.html#librdf-statement" title="librdf_statement"><span class="type">librdf_statement</span></a> *statement</code></em>); |
| 79 | <a class="link" href="redland-stream.html#librdf-stream" title="librdf_stream"><span class="returnvalue">librdf_stream</span></a> * <a class="link" href="redland-storage.html#librdf-storage-serialise" title="librdf_storage_serialise ()">librdf_storage_serialise</a> (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>); |
| 80 | <a class="link" href="redland-stream.html#librdf-stream" title="librdf_stream"><span class="returnvalue">librdf_stream</span></a> * <a class="link" href="redland-storage.html#librdf-storage-find-statements" title="librdf_storage_find_statements ()">librdf_storage_find_statements</a> (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>, |
| 81 | <em class="parameter"><code><a class="link" href="redland-statement.html#librdf-statement" title="librdf_statement"><span class="type">librdf_statement</span></a> *statement</code></em>); |
| 82 | <a class="link" href="redland-stream.html#librdf-stream" title="librdf_stream"><span class="returnvalue">librdf_stream</span></a> * <a class="link" href="redland-storage.html#librdf-storage-find-statements-with-options" title="librdf_storage_find_statements_with_options ()">librdf_storage_find_statements_with_options</a> |
| 83 | (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>, |
| 84 | <em class="parameter"><code><a class="link" href="redland-statement.html#librdf-statement" title="librdf_statement"><span class="type">librdf_statement</span></a> *statement</code></em>, |
| 85 | <em class="parameter"><code><a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> *context_node</code></em>, |
| 86 | <em class="parameter"><code><a class="link" href="redland-hash.html#librdf-hash" title="librdf_hash"><span class="type">librdf_hash</span></a> *options</code></em>); |
| 87 | <a class="link" href="redland-iterator.html#librdf-iterator" title="librdf_iterator"><span class="returnvalue">librdf_iterator</span></a> * <a class="link" href="redland-storage.html#librdf-storage-get-sources" title="librdf_storage_get_sources ()">librdf_storage_get_sources</a> (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>, |
| 88 | <em class="parameter"><code><a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> *arc</code></em>, |
| 89 | <em class="parameter"><code><a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> *target</code></em>); |
| 90 | <a class="link" href="redland-iterator.html#librdf-iterator" title="librdf_iterator"><span class="returnvalue">librdf_iterator</span></a> * <a class="link" href="redland-storage.html#librdf-storage-get-arcs" title="librdf_storage_get_arcs ()">librdf_storage_get_arcs</a> (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>, |
| 91 | <em class="parameter"><code><a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> *source</code></em>, |
| 92 | <em class="parameter"><code><a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> *target</code></em>); |
| 93 | <a class="link" href="redland-iterator.html#librdf-iterator" title="librdf_iterator"><span class="returnvalue">librdf_iterator</span></a> * <a class="link" href="redland-storage.html#librdf-storage-get-targets" title="librdf_storage_get_targets ()">librdf_storage_get_targets</a> (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>, |
| 94 | <em class="parameter"><code><a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> *source</code></em>, |
| 95 | <em class="parameter"><code><a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> *arc</code></em>); |
| 96 | <a class="link" href="redland-iterator.html#librdf-iterator" title="librdf_iterator"><span class="returnvalue">librdf_iterator</span></a> * <a class="link" href="redland-storage.html#librdf-storage-get-arcs-in" title="librdf_storage_get_arcs_in ()">librdf_storage_get_arcs_in</a> (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>, |
| 97 | <em class="parameter"><code><a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> *node</code></em>); |
| 98 | <a class="link" href="redland-iterator.html#librdf-iterator" title="librdf_iterator"><span class="returnvalue">librdf_iterator</span></a> * <a class="link" href="redland-storage.html#librdf-storage-get-arcs-out" title="librdf_storage_get_arcs_out ()">librdf_storage_get_arcs_out</a> (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>, |
| 99 | <em class="parameter"><code><a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> *node</code></em>); |
| 100 | <span class="returnvalue">int</span> <a class="link" href="redland-storage.html#librdf-storage-has-arc-in" title="librdf_storage_has_arc_in ()">librdf_storage_has_arc_in</a> (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>, |
| 101 | <em class="parameter"><code><a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> *node</code></em>, |
| 102 | <em class="parameter"><code><a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> *property</code></em>); |
| 103 | <span class="returnvalue">int</span> <a class="link" href="redland-storage.html#librdf-storage-has-arc-out" title="librdf_storage_has_arc_out ()">librdf_storage_has_arc_out</a> (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>, |
| 104 | <em class="parameter"><code><a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> *node</code></em>, |
| 105 | <em class="parameter"><code><a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> *property</code></em>); |
| 106 | <span class="returnvalue">int</span> <a class="link" href="redland-storage.html#librdf-storage-context-add-statement" title="librdf_storage_context_add_statement ()">librdf_storage_context_add_statement</a> |
| 107 | (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>, |
| 108 | <em class="parameter"><code><a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> *context</code></em>, |
| 109 | <em class="parameter"><code><a class="link" href="redland-statement.html#librdf-statement" title="librdf_statement"><span class="type">librdf_statement</span></a> *statement</code></em>); |
| 110 | <span class="returnvalue">int</span> <a class="link" href="redland-storage.html#librdf-storage-context-add-statements" title="librdf_storage_context_add_statements ()">librdf_storage_context_add_statements</a> |
| 111 | (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>, |
| 112 | <em class="parameter"><code><a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> *context</code></em>, |
| 113 | <em class="parameter"><code><a class="link" href="redland-stream.html#librdf-stream" title="librdf_stream"><span class="type">librdf_stream</span></a> *stream</code></em>); |
| 114 | <span class="returnvalue">int</span> <a class="link" href="redland-storage.html#librdf-storage-context-remove-statement" title="librdf_storage_context_remove_statement ()">librdf_storage_context_remove_statement</a> |
| 115 | (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>, |
| 116 | <em class="parameter"><code><a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> *context</code></em>, |
| 117 | <em class="parameter"><code><a class="link" href="redland-statement.html#librdf-statement" title="librdf_statement"><span class="type">librdf_statement</span></a> *statement</code></em>); |
| 118 | <span class="returnvalue">int</span> <a class="link" href="redland-storage.html#librdf-storage-context-remove-statements" title="librdf_storage_context_remove_statements ()">librdf_storage_context_remove_statements</a> |
| 119 | (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>, |
| 120 | <em class="parameter"><code><a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> *context</code></em>); |
| 121 | <a class="link" href="redland-stream.html#librdf-stream" title="librdf_stream"><span class="returnvalue">librdf_stream</span></a> * <a class="link" href="redland-storage.html#librdf-storage-context-as-stream" title="librdf_storage_context_as_stream ()">librdf_storage_context_as_stream</a> (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>, |
| 122 | <em class="parameter"><code><a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> *context</code></em>); |
| 123 | <a class="link" href="redland-stream.html#librdf-stream" title="librdf_stream"><span class="returnvalue">librdf_stream</span></a> * <a class="link" href="redland-storage.html#librdf-storage-context-serialise" title="librdf_storage_context_serialise ()">librdf_storage_context_serialise</a> (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>, |
| 124 | <em class="parameter"><code><a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> *context</code></em>); |
| 125 | <span class="returnvalue">int</span> <a class="link" href="redland-storage.html#librdf-storage-supports-query" title="librdf_storage_supports_query ()">librdf_storage_supports_query</a> (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>, |
| 126 | <em class="parameter"><code><a class="link" href="redland-query.html#librdf-query" title="librdf_query"><span class="type">librdf_query</span></a> *query</code></em>); |
| 127 | <a class="link" href="redland-query-results.html#librdf-query-results" title="librdf_query_results"><span class="returnvalue">librdf_query_results</span></a> * <a class="link" href="redland-storage.html#librdf-storage-query-execute" title="librdf_storage_query_execute ()">librdf_storage_query_execute</a> (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>, |
| 128 | <em class="parameter"><code><a class="link" href="redland-query.html#librdf-query" title="librdf_query"><span class="type">librdf_query</span></a> *query</code></em>); |
| 129 | <span class="returnvalue">int</span> <a class="link" href="redland-storage.html#librdf-storage-sync" title="librdf_storage_sync ()">librdf_storage_sync</a> (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>); |
| 130 | <a class="link" href="redland-stream.html#librdf-stream" title="librdf_stream"><span class="returnvalue">librdf_stream</span></a> * <a class="link" href="redland-storage.html#librdf-storage-find-statements-in-context" title="librdf_storage_find_statements_in_context ()">librdf_storage_find_statements_in_context</a> |
| 131 | (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>, |
| 132 | <em class="parameter"><code><a class="link" href="redland-statement.html#librdf-statement" title="librdf_statement"><span class="type">librdf_statement</span></a> *statement</code></em>, |
| 133 | <em class="parameter"><code><a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> *context_node</code></em>); |
| 134 | <a class="link" href="redland-iterator.html#librdf-iterator" title="librdf_iterator"><span class="returnvalue">librdf_iterator</span></a> * <a class="link" href="redland-storage.html#librdf-storage-get-contexts" title="librdf_storage_get_contexts ()">librdf_storage_get_contexts</a> (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>); |
| 135 | <a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="returnvalue">librdf_node</span></a> * <a class="link" href="redland-storage.html#librdf-storage-get-feature" title="librdf_storage_get_feature ()">librdf_storage_get_feature</a> (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>, |
| 136 | <em class="parameter"><code><a class="link" href="redland-uri.html#librdf-uri" title="librdf_uri"><span class="type">librdf_uri</span></a> *feature</code></em>); |
| 137 | <span class="returnvalue">int</span> <a class="link" href="redland-storage.html#librdf-storage-set-feature" title="librdf_storage_set_feature ()">librdf_storage_set_feature</a> (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>, |
| 138 | <em class="parameter"><code><a class="link" href="redland-uri.html#librdf-uri" title="librdf_uri"><span class="type">librdf_uri</span></a> *feature</code></em>, |
| 139 | <em class="parameter"><code><a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> *value</code></em>); |
| 140 | <span class="returnvalue">int</span> <a class="link" href="redland-storage.html#librdf-storage-transaction-commit" title="librdf_storage_transaction_commit ()">librdf_storage_transaction_commit</a> (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>); |
| 141 | <span class="returnvalue">void</span> * <a class="link" href="redland-storage.html#librdf-storage-transaction-get-handle" title="librdf_storage_transaction_get_handle ()">librdf_storage_transaction_get_handle</a> |
| 142 | (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>); |
| 143 | <span class="returnvalue">int</span> <a class="link" href="redland-storage.html#librdf-storage-transaction-rollback" title="librdf_storage_transaction_rollback ()">librdf_storage_transaction_rollback</a> (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>); |
| 144 | <span class="returnvalue">int</span> <a class="link" href="redland-storage.html#librdf-storage-transaction-start" title="librdf_storage_transaction_start ()">librdf_storage_transaction_start</a> (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>); |
| 145 | <span class="returnvalue">int</span> <a class="link" href="redland-storage.html#librdf-storage-transaction-start-with-handle" title="librdf_storage_transaction_start_with_handle ()">librdf_storage_transaction_start_with_handle</a> |
| 146 | (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>, |
| 147 | <em class="parameter"><code><span class="type">void</span> *handle</code></em>); |
| 148 | <span class="returnvalue">void</span> <a class="link" href="redland-storage.html#librdf-storage-add-reference" title="librdf_storage_add_reference ()">librdf_storage_add_reference</a> (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>); |
| 149 | <span class="returnvalue">void</span> <a class="link" href="redland-storage.html#librdf-storage-remove-reference" title="librdf_storage_remove_reference ()">librdf_storage_remove_reference</a> (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>); |
| 150 | typedef <a class="link" href="redland-storage.html#librdf-storage-instance" title="librdf_storage_instance">librdf_storage_instance</a>; |
| 151 | <a class="link" href="redland-storage.html#librdf-storage-instance" title="librdf_storage_instance"><span class="returnvalue">librdf_storage_instance</span></a> <a class="link" href="redland-storage.html#librdf-storage-get-instance" title="librdf_storage_get_instance ()">librdf_storage_get_instance</a> (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>); |
| 152 | <span class="returnvalue">void</span> <a class="link" href="redland-storage.html#librdf-storage-set-instance" title="librdf_storage_set_instance ()">librdf_storage_set_instance</a> (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>, |
| 153 | <em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage-instance" title="librdf_storage_instance"><span class="type">librdf_storage_instance</span></a> instance</code></em>); |
| 154 | <a class="link" href="redland-world.html#librdf-world" title="librdf_world"><span class="returnvalue">librdf_world</span></a> * <a class="link" href="redland-storage.html#librdf-storage-get-world" title="librdf_storage_get_world ()">librdf_storage_get_world</a> (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>); |
| 155 | <span class="returnvalue">void</span> (<a class="link" href="redland-storage.html#librdf-storage-module-register-function" title="librdf_storage_module_register_function ()">*librdf_storage_module_register_function</a>) |
| 156 | (<em class="parameter"><code><a class="link" href="redland-world.html#librdf-world" title="librdf_world"><span class="type">librdf_world</span></a> *world</code></em>); |
| 157 | </pre> |
| 158 | </div> |
| 159 | <div class="refsect1"> |
| 160 | <a name="redland-storage.description"></a><h2>Description</h2> |
| 161 | <p> |
| 162 | Provides classes to create triple stores to back the RDF graph |
| 163 | interface (<a class="link" href="redland-model.html#librdf-model" title="librdf_model"><span class="type">librdf_model</span></a>). Most of the methods are for implementing |
| 164 | the RDF model API and have the same name. |
| 165 | </p> |
| 166 | </div> |
| 167 | <div class="refsect1"> |
| 168 | <a name="redland-storage.details"></a><h2>Details</h2> |
| 169 | <div class="refsect2"> |
| 170 | <a name="LIBRDF-STORAGE-INTERFACE-VERSION:CAPS"></a><h3>LIBRDF_STORAGE_INTERFACE_VERSION</h3> |
| 171 | <pre class="programlisting">#define LIBRDF_STORAGE_INTERFACE_VERSION LIBRDF_STORAGE_MAX_INTERFACE_VERSION |
| 172 | </pre> |
| 173 | <p> |
| 174 | Default librdf storage module interface version. |
| 175 | </p> |
| 176 | </div> |
| 177 | <hr> |
| 178 | <div class="refsect2"> |
| 179 | <a name="LIBRDF-STORAGE-MAX-INTERFACE-VERSION:CAPS"></a><h3>LIBRDF_STORAGE_MAX_INTERFACE_VERSION</h3> |
| 180 | <pre class="programlisting">#define LIBRDF_STORAGE_MAX_INTERFACE_VERSION 1 |
| 181 | </pre> |
| 182 | <p> |
| 183 | Newest supported librdf storage module interface version. |
| 184 | </p> |
| 185 | </div> |
| 186 | <hr> |
| 187 | <div class="refsect2"> |
| 188 | <a name="LIBRDF-STORAGE-MIN-INTERFACE-VERSION:CAPS"></a><h3>LIBRDF_STORAGE_MIN_INTERFACE_VERSION</h3> |
| 189 | <pre class="programlisting">#define LIBRDF_STORAGE_MIN_INTERFACE_VERSION 1 |
| 190 | </pre> |
| 191 | <p> |
| 192 | Oldest support librdf storage module interface version. |
| 193 | </p> |
| 194 | </div> |
| 195 | <hr> |
| 196 | <div class="refsect2"> |
| 197 | <a name="librdf-storage"></a><h3>librdf_storage</h3> |
| 198 | <pre class="programlisting">typedef struct librdf_storage_s librdf_storage; |
| 199 | </pre> |
| 200 | <p> |
| 201 | Redland storage class. |
| 202 | </p> |
| 203 | </div> |
| 204 | <hr> |
| 205 | <div class="refsect2"> |
| 206 | <a name="librdf-storage-factory"></a><h3>librdf_storage_factory</h3> |
| 207 | <pre class="programlisting">typedef struct librdf_storage_factory_s librdf_storage_factory; |
| 208 | </pre> |
| 209 | <p> |
| 210 | A Storage Factory |
| 211 | </p> |
| 212 | </div> |
| 213 | <hr> |
| 214 | <div class="refsect2"> |
| 215 | <a name="librdf-storage-register-factory"></a><h3>librdf_storage_register_factory ()</h3> |
| 216 | <pre class="programlisting"><span class="returnvalue">int</span> librdf_storage_register_factory (<em class="parameter"><code><a class="link" href="redland-world.html#librdf-world" title="librdf_world"><span class="type">librdf_world</span></a> *world</code></em>, |
| 217 | <em class="parameter"><code>const <span class="type">char</span> *name</code></em>, |
| 218 | <em class="parameter"><code>const <span class="type">char</span> *label</code></em>, |
| 219 | <em class="parameter"><code><span class="type">void</span> (*factory) (librdf_storage_factory*)</code></em>);</pre> |
| 220 | <p> |
| 221 | Register a storage factory. |
| 222 | </p> |
| 223 | <p> |
| 224 | Registration will fail if any of the parameters or NULL, if the factory |
| 225 | API version is out of the known range or if out of memory. |
| 226 | </p> |
| 227 | <div class="variablelist"><table border="0"> |
| 228 | <col align="left" valign="top"> |
| 229 | <tbody> |
| 230 | <tr> |
| 231 | <td><p><span class="term"><em class="parameter"><code>world</code></em> :</span></p></td> |
| 232 | <td>redland world object</td> |
| 233 | </tr> |
| 234 | <tr> |
| 235 | <td><p><span class="term"><em class="parameter"><code>name</code></em> :</span></p></td> |
| 236 | <td>the storage factory name</td> |
| 237 | </tr> |
| 238 | <tr> |
| 239 | <td><p><span class="term"><em class="parameter"><code>label</code></em> :</span></p></td> |
| 240 | <td>the storage factory label</td> |
| 241 | </tr> |
| 242 | <tr> |
| 243 | <td><p><span class="term"><em class="parameter"><code>factory</code></em> :</span></p></td> |
| 244 | <td>pointer to function to call to register the factory</td> |
| 245 | </tr> |
| 246 | <tr> |
| 247 | <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td> |
| 248 | <td>non-0 on failure</td> |
| 249 | </tr> |
| 250 | </tbody> |
| 251 | </table></div> |
| 252 | </div> |
| 253 | <hr> |
| 254 | <div class="refsect2"> |
| 255 | <a name="librdf-storage-enumerate"></a><h3>librdf_storage_enumerate ()</h3> |
| 256 | <pre class="programlisting"><span class="returnvalue">int</span> librdf_storage_enumerate (<em class="parameter"><code><a class="link" href="redland-world.html#librdf-world" title="librdf_world"><span class="type">librdf_world</span></a> *world</code></em>, |
| 257 | <em class="parameter"><code>const unsigned <span class="type">int</span> counter</code></em>, |
| 258 | <em class="parameter"><code>const <span class="type">char</span> **name</code></em>, |
| 259 | <em class="parameter"><code>const <span class="type">char</span> **label</code></em>);</pre> |
| 260 | <p> |
| 261 | Get information on storages. |
| 262 | </p> |
| 263 | <div class="variablelist"><table border="0"> |
| 264 | <col align="left" valign="top"> |
| 265 | <tbody> |
| 266 | <tr> |
| 267 | <td><p><span class="term"><em class="parameter"><code>world</code></em> :</span></p></td> |
| 268 | <td>redland world object</td> |
| 269 | </tr> |
| 270 | <tr> |
| 271 | <td><p><span class="term"><em class="parameter"><code>counter</code></em> :</span></p></td> |
| 272 | <td>index into the list of storages</td> |
| 273 | </tr> |
| 274 | <tr> |
| 275 | <td><p><span class="term"><em class="parameter"><code>name</code></em> :</span></p></td> |
| 276 | <td>pointer to store the name of the storage (or NULL)</td> |
| 277 | </tr> |
| 278 | <tr> |
| 279 | <td><p><span class="term"><em class="parameter"><code>label</code></em> :</span></p></td> |
| 280 | <td>pointer to store syntax readable label (or NULL)</td> |
| 281 | </tr> |
| 282 | <tr> |
| 283 | <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td> |
| 284 | <td>non 0 on failure of if counter is out of range</td> |
| 285 | </tr> |
| 286 | </tbody> |
| 287 | </table></div> |
| 288 | </div> |
| 289 | <hr> |
| 290 | <div class="refsect2"> |
| 291 | <a name="librdf-new-storage"></a><h3>librdf_new_storage ()</h3> |
| 292 | <pre class="programlisting"><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="returnvalue">librdf_storage</span></a> * librdf_new_storage (<em class="parameter"><code><a class="link" href="redland-world.html#librdf-world" title="librdf_world"><span class="type">librdf_world</span></a> *world</code></em>, |
| 293 | <em class="parameter"><code>const <span class="type">char</span> *storage_name</code></em>, |
| 294 | <em class="parameter"><code>const <span class="type">char</span> *name</code></em>, |
| 295 | <em class="parameter"><code>const <span class="type">char</span> *options_string</code></em>);</pre> |
| 296 | <p> |
| 297 | Constructor - create a new <a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> object. |
| 298 | </p> |
| 299 | <p> |
| 300 | The options are encoded as described in <a class="link" href="redland-hash.html#librdf-hash-from-string" title="librdf_hash_from_string ()"><code class="function">librdf_hash_from_string()</code></a> |
| 301 | and can be NULL if none are required. |
| 302 | </p> |
| 303 | <div class="variablelist"><table border="0"> |
| 304 | <col align="left" valign="top"> |
| 305 | <tbody> |
| 306 | <tr> |
| 307 | <td><p><span class="term"><em class="parameter"><code>world</code></em> :</span></p></td> |
| 308 | <td>redland world object</td> |
| 309 | </tr> |
| 310 | <tr> |
| 311 | <td><p><span class="term"><em class="parameter"><code>storage_name</code></em> :</span></p></td> |
| 312 | <td>the storage factory name</td> |
| 313 | </tr> |
| 314 | <tr> |
| 315 | <td><p><span class="term"><em class="parameter"><code>name</code></em> :</span></p></td> |
| 316 | <td>an identifier for the storage</td> |
| 317 | </tr> |
| 318 | <tr> |
| 319 | <td><p><span class="term"><em class="parameter"><code>options_string</code></em> :</span></p></td> |
| 320 | <td>options to initialise storage</td> |
| 321 | </tr> |
| 322 | <tr> |
| 323 | <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td> |
| 324 | <td>a new <a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> object or NULL on failure</td> |
| 325 | </tr> |
| 326 | </tbody> |
| 327 | </table></div> |
| 328 | </div> |
| 329 | <hr> |
| 330 | <div class="refsect2"> |
| 331 | <a name="librdf-new-storage-with-options"></a><h3>librdf_new_storage_with_options ()</h3> |
| 332 | <pre class="programlisting"><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="returnvalue">librdf_storage</span></a> * librdf_new_storage_with_options (<em class="parameter"><code><a class="link" href="redland-world.html#librdf-world" title="librdf_world"><span class="type">librdf_world</span></a> *world</code></em>, |
| 333 | <em class="parameter"><code>const <span class="type">char</span> *storage_name</code></em>, |
| 334 | <em class="parameter"><code>const <span class="type">char</span> *name</code></em>, |
| 335 | <em class="parameter"><code><a class="link" href="redland-hash.html#librdf-hash" title="librdf_hash"><span class="type">librdf_hash</span></a> *options</code></em>);</pre> |
| 336 | <p> |
| 337 | Constructor - create a new <a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> object. |
| 338 | </p> |
| 339 | <p> |
| 340 | The options can be NULL if none are required. |
| 341 | </p> |
| 342 | <div class="variablelist"><table border="0"> |
| 343 | <col align="left" valign="top"> |
| 344 | <tbody> |
| 345 | <tr> |
| 346 | <td><p><span class="term"><em class="parameter"><code>world</code></em> :</span></p></td> |
| 347 | <td>redland world object</td> |
| 348 | </tr> |
| 349 | <tr> |
| 350 | <td><p><span class="term"><em class="parameter"><code>storage_name</code></em> :</span></p></td> |
| 351 | <td>the storage factory name</td> |
| 352 | </tr> |
| 353 | <tr> |
| 354 | <td><p><span class="term"><em class="parameter"><code>name</code></em> :</span></p></td> |
| 355 | <td>an identifier for the storage</td> |
| 356 | </tr> |
| 357 | <tr> |
| 358 | <td><p><span class="term"><em class="parameter"><code>options</code></em> :</span></p></td> |
| 359 | <td> |
| 360 | <a class="link" href="redland-hash.html#librdf-hash" title="librdf_hash"><span class="type">librdf_hash</span></a> of options to use</td> |
| 361 | </tr> |
| 362 | <tr> |
| 363 | <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td> |
| 364 | <td>a new <a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> object or NULL on failure</td> |
| 365 | </tr> |
| 366 | </tbody> |
| 367 | </table></div> |
| 368 | </div> |
| 369 | <hr> |
| 370 | <div class="refsect2"> |
| 371 | <a name="librdf-new-storage-from-storage"></a><h3>librdf_new_storage_from_storage ()</h3> |
| 372 | <pre class="programlisting"><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="returnvalue">librdf_storage</span></a> * librdf_new_storage_from_storage (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *old_storage</code></em>);</pre> |
| 373 | <p> |
| 374 | Copy constructor - create a new librdf_storage object from an existing one |
| 375 | </p> |
| 376 | <p> |
| 377 | Should create a new storage in the same context as the existing one |
| 378 | as appropriate for the storage. For example, in a RDBMS storage |
| 379 | it would be a new database, or in on disk it would be a new |
| 380 | set of files. This will mean automatically generating |
| 381 | a new identifier for the storage, maybe based on the existing |
| 382 | storage identifier. |
| 383 | </p> |
| 384 | <div class="variablelist"><table border="0"> |
| 385 | <col align="left" valign="top"> |
| 386 | <tbody> |
| 387 | <tr> |
| 388 | <td><p><span class="term"><em class="parameter"><code>old_storage</code></em> :</span></p></td> |
| 389 | <td>the existing storage <a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> to use</td> |
| 390 | </tr> |
| 391 | <tr> |
| 392 | <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td> |
| 393 | <td>a new <a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> object or NULL on failure</td> |
| 394 | </tr> |
| 395 | </tbody> |
| 396 | </table></div> |
| 397 | </div> |
| 398 | <hr> |
| 399 | <div class="refsect2"> |
| 400 | <a name="librdf-new-storage-from-factory"></a><h3>librdf_new_storage_from_factory ()</h3> |
| 401 | <pre class="programlisting"><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="returnvalue">librdf_storage</span></a> * librdf_new_storage_from_factory (<em class="parameter"><code><a class="link" href="redland-world.html#librdf-world" title="librdf_world"><span class="type">librdf_world</span></a> *world</code></em>, |
| 402 | <em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage-factory" title="librdf_storage_factory"><span class="type">librdf_storage_factory</span></a> *factory</code></em>, |
| 403 | <em class="parameter"><code>const <span class="type">char</span> *name</code></em>, |
| 404 | <em class="parameter"><code><a class="link" href="redland-hash.html#librdf-hash" title="librdf_hash"><span class="type">librdf_hash</span></a> *options</code></em>);</pre> |
| 405 | <p> |
| 406 | Constructor - create a new <a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> object. |
| 407 | </p> |
| 408 | <p> |
| 409 | If the options are present, they become owned by the storage |
| 410 | and should no longer be used. |
| 411 | </p> |
| 412 | <div class="variablelist"><table border="0"> |
| 413 | <col align="left" valign="top"> |
| 414 | <tbody> |
| 415 | <tr> |
| 416 | <td><p><span class="term"><em class="parameter"><code>world</code></em> :</span></p></td> |
| 417 | <td>redland world object</td> |
| 418 | </tr> |
| 419 | <tr> |
| 420 | <td><p><span class="term"><em class="parameter"><code>factory</code></em> :</span></p></td> |
| 421 | <td>the factory to use to construct the storage</td> |
| 422 | </tr> |
| 423 | <tr> |
| 424 | <td><p><span class="term"><em class="parameter"><code>name</code></em> :</span></p></td> |
| 425 | <td>name to use for storage</td> |
| 426 | </tr> |
| 427 | <tr> |
| 428 | <td><p><span class="term"><em class="parameter"><code>options</code></em> :</span></p></td> |
| 429 | <td> |
| 430 | <a class="link" href="redland-hash.html#librdf-hash" title="librdf_hash"><span class="type">librdf_hash</span></a> of options to initialise storage</td> |
| 431 | </tr> |
| 432 | <tr> |
| 433 | <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td> |
| 434 | <td>a new <a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> object or NULL on failure</td> |
| 435 | </tr> |
| 436 | </tbody> |
| 437 | </table></div> |
| 438 | </div> |
| 439 | <hr> |
| 440 | <div class="refsect2"> |
| 441 | <a name="librdf-free-storage"></a><h3>librdf_free_storage ()</h3> |
| 442 | <pre class="programlisting"><span class="returnvalue">void</span> librdf_free_storage (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>);</pre> |
| 443 | <p> |
| 444 | Destructor - destroy a <a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> object. |
| 445 | </p> |
| 446 | <div class="variablelist"><table border="0"> |
| 447 | <col align="left" valign="top"> |
| 448 | <tbody><tr> |
| 449 | <td><p><span class="term"><em class="parameter"><code>storage</code></em> :</span></p></td> |
| 450 | <td> |
| 451 | <a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> object</td> |
| 452 | </tr></tbody> |
| 453 | </table></div> |
| 454 | </div> |
| 455 | <hr> |
| 456 | <div class="refsect2"> |
| 457 | <a name="librdf-storage-open"></a><h3>librdf_storage_open ()</h3> |
| 458 | <pre class="programlisting"><span class="returnvalue">int</span> librdf_storage_open (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>, |
| 459 | <em class="parameter"><code><a class="link" href="redland-model.html#librdf-model" title="librdf_model"><span class="type">librdf_model</span></a> *model</code></em>);</pre> |
| 460 | <p> |
| 461 | Start a model / storage association. |
| 462 | </p> |
| 463 | <p> |
| 464 | This is ended with <a class="link" href="redland-storage.html#librdf-storage-close" title="librdf_storage_close ()"><code class="function">librdf_storage_close()</code></a> |
| 465 | </p> |
| 466 | <div class="variablelist"><table border="0"> |
| 467 | <col align="left" valign="top"> |
| 468 | <tbody> |
| 469 | <tr> |
| 470 | <td><p><span class="term"><em class="parameter"><code>storage</code></em> :</span></p></td> |
| 471 | <td> |
| 472 | <a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> object</td> |
| 473 | </tr> |
| 474 | <tr> |
| 475 | <td><p><span class="term"><em class="parameter"><code>model</code></em> :</span></p></td> |
| 476 | <td>model stored</td> |
| 477 | </tr> |
| 478 | <tr> |
| 479 | <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td> |
| 480 | <td>non 0 on failure</td> |
| 481 | </tr> |
| 482 | </tbody> |
| 483 | </table></div> |
| 484 | </div> |
| 485 | <hr> |
| 486 | <div class="refsect2"> |
| 487 | <a name="librdf-storage-close"></a><h3>librdf_storage_close ()</h3> |
| 488 | <pre class="programlisting"><span class="returnvalue">int</span> librdf_storage_close (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>);</pre> |
| 489 | <p> |
| 490 | End a model / storage association. |
| 491 | </p> |
| 492 | <div class="variablelist"><table border="0"> |
| 493 | <col align="left" valign="top"> |
| 494 | <tbody> |
| 495 | <tr> |
| 496 | <td><p><span class="term"><em class="parameter"><code>storage</code></em> :</span></p></td> |
| 497 | <td> |
| 498 | <a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> object</td> |
| 499 | </tr> |
| 500 | <tr> |
| 501 | <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td> |
| 502 | <td>non 0 on failure</td> |
| 503 | </tr> |
| 504 | </tbody> |
| 505 | </table></div> |
| 506 | </div> |
| 507 | <hr> |
| 508 | <div class="refsect2"> |
| 509 | <a name="librdf-storage-size"></a><h3>librdf_storage_size ()</h3> |
| 510 | <pre class="programlisting"><span class="returnvalue">int</span> librdf_storage_size (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>);</pre> |
| 511 | <p> |
| 512 | Get the number of statements stored. |
| 513 | </p> |
| 514 | <div class="variablelist"><table border="0"> |
| 515 | <col align="left" valign="top"> |
| 516 | <tbody> |
| 517 | <tr> |
| 518 | <td><p><span class="term"><em class="parameter"><code>storage</code></em> :</span></p></td> |
| 519 | <td> |
| 520 | <a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> object</td> |
| 521 | </tr> |
| 522 | <tr> |
| 523 | <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td> |
| 524 | <td>The number of statements or < 0 if cannot be determined</td> |
| 525 | </tr> |
| 526 | </tbody> |
| 527 | </table></div> |
| 528 | </div> |
| 529 | <hr> |
| 530 | <div class="refsect2"> |
| 531 | <a name="librdf-storage-add-statement"></a><h3>librdf_storage_add_statement ()</h3> |
| 532 | <pre class="programlisting"><span class="returnvalue">int</span> librdf_storage_add_statement (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>, |
| 533 | <em class="parameter"><code><a class="link" href="redland-statement.html#librdf-statement" title="librdf_statement"><span class="type">librdf_statement</span></a> *statement</code></em>);</pre> |
| 534 | <p> |
| 535 | Add a statement to a storage. |
| 536 | </p> |
| 537 | <p> |
| 538 | The passed-in statement is copied when added to the store, not |
| 539 | shared with the store. |
| 540 | </p> |
| 541 | <p> |
| 542 | If the statement already exists in the store, it is not added |
| 543 | unless Redland contexts are being used. |
| 544 | </p> |
| 545 | <p> |
| 546 | Enforces that the statement is legal for RDF - URI or blank subject, |
| 547 | URI predicate and URI or blank or literal object (i.e. anything). |
| 548 | </p> |
| 549 | <div class="variablelist"><table border="0"> |
| 550 | <col align="left" valign="top"> |
| 551 | <tbody> |
| 552 | <tr> |
| 553 | <td><p><span class="term"><em class="parameter"><code>storage</code></em> :</span></p></td> |
| 554 | <td> |
| 555 | <a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> object</td> |
| 556 | </tr> |
| 557 | <tr> |
| 558 | <td><p><span class="term"><em class="parameter"><code>statement</code></em> :</span></p></td> |
| 559 | <td> |
| 560 | <a class="link" href="redland-statement.html#librdf-statement" title="librdf_statement"><span class="type">librdf_statement</span></a> statement to add</td> |
| 561 | </tr> |
| 562 | <tr> |
| 563 | <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td> |
| 564 | <td>non 0 on failure, <0 on error, >0 if statement was illegal</td> |
| 565 | </tr> |
| 566 | </tbody> |
| 567 | </table></div> |
| 568 | </div> |
| 569 | <hr> |
| 570 | <div class="refsect2"> |
| 571 | <a name="librdf-storage-add-statements"></a><h3>librdf_storage_add_statements ()</h3> |
| 572 | <pre class="programlisting"><span class="returnvalue">int</span> librdf_storage_add_statements (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>, |
| 573 | <em class="parameter"><code><a class="link" href="redland-stream.html#librdf-stream" title="librdf_stream"><span class="type">librdf_stream</span></a> *statement_stream</code></em>);</pre> |
| 574 | <p> |
| 575 | Add a stream of statements to the storage. |
| 576 | </p> |
| 577 | <p> |
| 578 | If any of the statements already exists in the store, they are not |
| 579 | added unless Redland contexts are being used. |
| 580 | </p> |
| 581 | <div class="variablelist"><table border="0"> |
| 582 | <col align="left" valign="top"> |
| 583 | <tbody> |
| 584 | <tr> |
| 585 | <td><p><span class="term"><em class="parameter"><code>storage</code></em> :</span></p></td> |
| 586 | <td> |
| 587 | <a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> object</td> |
| 588 | </tr> |
| 589 | <tr> |
| 590 | <td><p><span class="term"><em class="parameter"><code>statement_stream</code></em> :</span></p></td> |
| 591 | <td> |
| 592 | <a class="link" href="redland-stream.html#librdf-stream" title="librdf_stream"><span class="type">librdf_stream</span></a> of statements</td> |
| 593 | </tr> |
| 594 | <tr> |
| 595 | <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td> |
| 596 | <td>non 0 on failure</td> |
| 597 | </tr> |
| 598 | </tbody> |
| 599 | </table></div> |
| 600 | </div> |
| 601 | <hr> |
| 602 | <div class="refsect2"> |
| 603 | <a name="librdf-storage-remove-statement"></a><h3>librdf_storage_remove_statement ()</h3> |
| 604 | <pre class="programlisting"><span class="returnvalue">int</span> librdf_storage_remove_statement (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>, |
| 605 | <em class="parameter"><code><a class="link" href="redland-statement.html#librdf-statement" title="librdf_statement"><span class="type">librdf_statement</span></a> *statement</code></em>);</pre> |
| 606 | <p> |
| 607 | Remove a statement from the storage. |
| 608 | </p> |
| 609 | <div class="variablelist"><table border="0"> |
| 610 | <col align="left" valign="top"> |
| 611 | <tbody> |
| 612 | <tr> |
| 613 | <td><p><span class="term"><em class="parameter"><code>storage</code></em> :</span></p></td> |
| 614 | <td> |
| 615 | <a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> object</td> |
| 616 | </tr> |
| 617 | <tr> |
| 618 | <td><p><span class="term"><em class="parameter"><code>statement</code></em> :</span></p></td> |
| 619 | <td> |
| 620 | <a class="link" href="redland-statement.html#librdf-statement" title="librdf_statement"><span class="type">librdf_statement</span></a> statement to remove</td> |
| 621 | </tr> |
| 622 | <tr> |
| 623 | <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td> |
| 624 | <td>non 0 on failure</td> |
| 625 | </tr> |
| 626 | </tbody> |
| 627 | </table></div> |
| 628 | </div> |
| 629 | <hr> |
| 630 | <div class="refsect2"> |
| 631 | <a name="librdf-storage-contains-statement"></a><h3>librdf_storage_contains_statement ()</h3> |
| 632 | <pre class="programlisting"><span class="returnvalue">int</span> librdf_storage_contains_statement (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>, |
| 633 | <em class="parameter"><code><a class="link" href="redland-statement.html#librdf-statement" title="librdf_statement"><span class="type">librdf_statement</span></a> *statement</code></em>);</pre> |
| 634 | <p> |
| 635 | Test if a given statement is present in the storage. |
| 636 | </p> |
| 637 | <div class="variablelist"><table border="0"> |
| 638 | <col align="left" valign="top"> |
| 639 | <tbody> |
| 640 | <tr> |
| 641 | <td><p><span class="term"><em class="parameter"><code>storage</code></em> :</span></p></td> |
| 642 | <td> |
| 643 | <a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> object</td> |
| 644 | </tr> |
| 645 | <tr> |
| 646 | <td><p><span class="term"><em class="parameter"><code>statement</code></em> :</span></p></td> |
| 647 | <td> |
| 648 | <a class="link" href="redland-statement.html#librdf-statement" title="librdf_statement"><span class="type">librdf_statement</span></a> statement to check</td> |
| 649 | </tr> |
| 650 | <tr> |
| 651 | <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td> |
| 652 | <td>non 0 if the storage contains the statement (>0 if illegal statement)</td> |
| 653 | </tr> |
| 654 | </tbody> |
| 655 | </table></div> |
| 656 | </div> |
| 657 | <hr> |
| 658 | <div class="refsect2"> |
| 659 | <a name="librdf-storage-serialise"></a><h3>librdf_storage_serialise ()</h3> |
| 660 | <pre class="programlisting"><a class="link" href="redland-stream.html#librdf-stream" title="librdf_stream"><span class="returnvalue">librdf_stream</span></a> * librdf_storage_serialise (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>);</pre> |
| 661 | <p> |
| 662 | Serialise the storage as a librdf_stream of statemetns. |
| 663 | </p> |
| 664 | <div class="variablelist"><table border="0"> |
| 665 | <col align="left" valign="top"> |
| 666 | <tbody> |
| 667 | <tr> |
| 668 | <td><p><span class="term"><em class="parameter"><code>storage</code></em> :</span></p></td> |
| 669 | <td> |
| 670 | <a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> object</td> |
| 671 | </tr> |
| 672 | <tr> |
| 673 | <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td> |
| 674 | <td> |
| 675 | <a class="link" href="redland-stream.html#librdf-stream" title="librdf_stream"><span class="type">librdf_stream</span></a> of statements or NULL on failure</td> |
| 676 | </tr> |
| 677 | </tbody> |
| 678 | </table></div> |
| 679 | </div> |
| 680 | <hr> |
| 681 | <div class="refsect2"> |
| 682 | <a name="librdf-storage-find-statements"></a><h3>librdf_storage_find_statements ()</h3> |
| 683 | <pre class="programlisting"><a class="link" href="redland-stream.html#librdf-stream" title="librdf_stream"><span class="returnvalue">librdf_stream</span></a> * librdf_storage_find_statements (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>, |
| 684 | <em class="parameter"><code><a class="link" href="redland-statement.html#librdf-statement" title="librdf_statement"><span class="type">librdf_statement</span></a> *statement</code></em>);</pre> |
| 685 | <p> |
| 686 | Search the storage for matching statements. |
| 687 | </p> |
| 688 | <p> |
| 689 | Searches the storage for a (partial) statement as described in |
| 690 | <a class="link" href="redland-statement.html#librdf-statement-match" title="librdf_statement_match ()"><code class="function">librdf_statement_match()</code></a> and returns a <a class="link" href="redland-stream.html#librdf-stream" title="librdf_stream"><span class="type">librdf_stream</span></a> of |
| 691 | matching <a class="link" href="redland-statement.html#librdf-statement" title="librdf_statement"><span class="type">librdf_statement</span></a> objects. |
| 692 | </p> |
| 693 | <div class="variablelist"><table border="0"> |
| 694 | <col align="left" valign="top"> |
| 695 | <tbody> |
| 696 | <tr> |
| 697 | <td><p><span class="term"><em class="parameter"><code>storage</code></em> :</span></p></td> |
| 698 | <td> |
| 699 | <a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> object</td> |
| 700 | </tr> |
| 701 | <tr> |
| 702 | <td><p><span class="term"><em class="parameter"><code>statement</code></em> :</span></p></td> |
| 703 | <td> |
| 704 | <a class="link" href="redland-statement.html#librdf-statement" title="librdf_statement"><span class="type">librdf_statement</span></a> partial statement to find</td> |
| 705 | </tr> |
| 706 | <tr> |
| 707 | <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td> |
| 708 | <td> |
| 709 | <a class="link" href="redland-stream.html#librdf-stream" title="librdf_stream"><span class="type">librdf_stream</span></a> of matching statements (may be empty) or NULL on failure</td> |
| 710 | </tr> |
| 711 | </tbody> |
| 712 | </table></div> |
| 713 | </div> |
| 714 | <hr> |
| 715 | <div class="refsect2"> |
| 716 | <a name="librdf-storage-find-statements-with-options"></a><h3>librdf_storage_find_statements_with_options ()</h3> |
| 717 | <pre class="programlisting"><a class="link" href="redland-stream.html#librdf-stream" title="librdf_stream"><span class="returnvalue">librdf_stream</span></a> * librdf_storage_find_statements_with_options |
| 718 | (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>, |
| 719 | <em class="parameter"><code><a class="link" href="redland-statement.html#librdf-statement" title="librdf_statement"><span class="type">librdf_statement</span></a> *statement</code></em>, |
| 720 | <em class="parameter"><code><a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> *context_node</code></em>, |
| 721 | <em class="parameter"><code><a class="link" href="redland-hash.html#librdf-hash" title="librdf_hash"><span class="type">librdf_hash</span></a> *options</code></em>);</pre> |
| 722 | <p> |
| 723 | Search the storage for matching statements with match options. |
| 724 | </p> |
| 725 | <p> |
| 726 | Searches the storage for a (partial) statement as described in |
| 727 | <a class="link" href="redland-statement.html#librdf-statement-match" title="librdf_statement_match ()"><code class="function">librdf_statement_match()</code></a> and returns a <a class="link" href="redland-stream.html#librdf-stream" title="librdf_stream"><span class="type">librdf_stream</span></a> of |
| 728 | matching <a class="link" href="redland-statement.html#librdf-statement" title="librdf_statement"><span class="type">librdf_statement</span></a> objects. |
| 729 | </p> |
| 730 | <p> |
| 731 | If options is given then the match is made according to |
| 732 | the given options. If options is NULL, this is equivalent |
| 733 | to librdf_storage_find_statements_in_context. |
| 734 | </p> |
| 735 | <div class="variablelist"><table border="0"> |
| 736 | <col align="left" valign="top"> |
| 737 | <tbody> |
| 738 | <tr> |
| 739 | <td><p><span class="term"><em class="parameter"><code>storage</code></em> :</span></p></td> |
| 740 | <td> |
| 741 | <a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> object</td> |
| 742 | </tr> |
| 743 | <tr> |
| 744 | <td><p><span class="term"><em class="parameter"><code>statement</code></em> :</span></p></td> |
| 745 | <td> |
| 746 | <a class="link" href="redland-statement.html#librdf-statement" title="librdf_statement"><span class="type">librdf_statement</span></a> partial statement to find</td> |
| 747 | </tr> |
| 748 | <tr> |
| 749 | <td><p><span class="term"><em class="parameter"><code>context_node</code></em> :</span></p></td> |
| 750 | <td> |
| 751 | <a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> context node or NULL.</td> |
| 752 | </tr> |
| 753 | <tr> |
| 754 | <td><p><span class="term"><em class="parameter"><code>options</code></em> :</span></p></td> |
| 755 | <td> |
| 756 | <a class="link" href="redland-hash.html#librdf-hash" title="librdf_hash"><span class="type">librdf_hash</span></a> of matching options or NULL</td> |
| 757 | </tr> |
| 758 | <tr> |
| 759 | <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td> |
| 760 | <td> |
| 761 | <a class="link" href="redland-stream.html#librdf-stream" title="librdf_stream"><span class="type">librdf_stream</span></a> of matching statements (may be empty) or NULL on failure</td> |
| 762 | </tr> |
| 763 | </tbody> |
| 764 | </table></div> |
| 765 | </div> |
| 766 | <hr> |
| 767 | <div class="refsect2"> |
| 768 | <a name="librdf-storage-get-sources"></a><h3>librdf_storage_get_sources ()</h3> |
| 769 | <pre class="programlisting"><a class="link" href="redland-iterator.html#librdf-iterator" title="librdf_iterator"><span class="returnvalue">librdf_iterator</span></a> * librdf_storage_get_sources (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>, |
| 770 | <em class="parameter"><code><a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> *arc</code></em>, |
| 771 | <em class="parameter"><code><a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> *target</code></em>);</pre> |
| 772 | <p> |
| 773 | Return the sources (subjects) of arc in an RDF graph given arc (predicate) and target (object). |
| 774 | </p> |
| 775 | <p> |
| 776 | Searches the storage for arcs matching the given arc and target |
| 777 | and returns a list of the source <a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> objects as an iterator |
| 778 | </p> |
| 779 | <div class="variablelist"><table border="0"> |
| 780 | <col align="left" valign="top"> |
| 781 | <tbody> |
| 782 | <tr> |
| 783 | <td><p><span class="term"><em class="parameter"><code>storage</code></em> :</span></p></td> |
| 784 | <td> |
| 785 | <a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> object</td> |
| 786 | </tr> |
| 787 | <tr> |
| 788 | <td><p><span class="term"><em class="parameter"><code>arc</code></em> :</span></p></td> |
| 789 | <td> |
| 790 | <a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> arc</td> |
| 791 | </tr> |
| 792 | <tr> |
| 793 | <td><p><span class="term"><em class="parameter"><code>target</code></em> :</span></p></td> |
| 794 | <td> |
| 795 | <a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> target</td> |
| 796 | </tr> |
| 797 | <tr> |
| 798 | <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td> |
| 799 | <td> |
| 800 | <a class="link" href="redland-iterator.html#librdf-iterator" title="librdf_iterator"><span class="type">librdf_iterator</span></a> of <a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> objects (may be empty) or NULL on failure</td> |
| 801 | </tr> |
| 802 | </tbody> |
| 803 | </table></div> |
| 804 | </div> |
| 805 | <hr> |
| 806 | <div class="refsect2"> |
| 807 | <a name="librdf-storage-get-arcs"></a><h3>librdf_storage_get_arcs ()</h3> |
| 808 | <pre class="programlisting"><a class="link" href="redland-iterator.html#librdf-iterator" title="librdf_iterator"><span class="returnvalue">librdf_iterator</span></a> * librdf_storage_get_arcs (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>, |
| 809 | <em class="parameter"><code><a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> *source</code></em>, |
| 810 | <em class="parameter"><code><a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> *target</code></em>);</pre> |
| 811 | <p> |
| 812 | Return the arcs (predicates) of an arc in an RDF graph given source (subject) and target (object). |
| 813 | </p> |
| 814 | <p> |
| 815 | Searches the storage for arcs matching the given source and target |
| 816 | and returns a list of the arc <a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> objects as an iterator |
| 817 | </p> |
| 818 | <div class="variablelist"><table border="0"> |
| 819 | <col align="left" valign="top"> |
| 820 | <tbody> |
| 821 | <tr> |
| 822 | <td><p><span class="term"><em class="parameter"><code>storage</code></em> :</span></p></td> |
| 823 | <td> |
| 824 | <a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> object</td> |
| 825 | </tr> |
| 826 | <tr> |
| 827 | <td><p><span class="term"><em class="parameter"><code>source</code></em> :</span></p></td> |
| 828 | <td> |
| 829 | <a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> source</td> |
| 830 | </tr> |
| 831 | <tr> |
| 832 | <td><p><span class="term"><em class="parameter"><code>target</code></em> :</span></p></td> |
| 833 | <td> |
| 834 | <a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> target</td> |
| 835 | </tr> |
| 836 | <tr> |
| 837 | <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td> |
| 838 | <td> |
| 839 | <a class="link" href="redland-iterator.html#librdf-iterator" title="librdf_iterator"><span class="type">librdf_iterator</span></a> of <a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> objects (may be empty) or NULL on failure</td> |
| 840 | </tr> |
| 841 | </tbody> |
| 842 | </table></div> |
| 843 | </div> |
| 844 | <hr> |
| 845 | <div class="refsect2"> |
| 846 | <a name="librdf-storage-get-targets"></a><h3>librdf_storage_get_targets ()</h3> |
| 847 | <pre class="programlisting"><a class="link" href="redland-iterator.html#librdf-iterator" title="librdf_iterator"><span class="returnvalue">librdf_iterator</span></a> * librdf_storage_get_targets (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>, |
| 848 | <em class="parameter"><code><a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> *source</code></em>, |
| 849 | <em class="parameter"><code><a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> *arc</code></em>);</pre> |
| 850 | <p> |
| 851 | Return the targets (objects) of an arc in an RDF graph given source (subject) and arc (predicate). |
| 852 | </p> |
| 853 | <p> |
| 854 | Searches the storage for targets matching the given source and arc |
| 855 | and returns a list of the source <a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> objects as an iterator |
| 856 | </p> |
| 857 | <div class="variablelist"><table border="0"> |
| 858 | <col align="left" valign="top"> |
| 859 | <tbody> |
| 860 | <tr> |
| 861 | <td><p><span class="term"><em class="parameter"><code>storage</code></em> :</span></p></td> |
| 862 | <td> |
| 863 | <a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> object</td> |
| 864 | </tr> |
| 865 | <tr> |
| 866 | <td><p><span class="term"><em class="parameter"><code>source</code></em> :</span></p></td> |
| 867 | <td> |
| 868 | <a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> source</td> |
| 869 | </tr> |
| 870 | <tr> |
| 871 | <td><p><span class="term"><em class="parameter"><code>arc</code></em> :</span></p></td> |
| 872 | <td> |
| 873 | <a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> arc</td> |
| 874 | </tr> |
| 875 | <tr> |
| 876 | <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td> |
| 877 | <td> |
| 878 | <a class="link" href="redland-iterator.html#librdf-iterator" title="librdf_iterator"><span class="type">librdf_iterator</span></a> of <a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> objects (may be empty) or NULL on failure</td> |
| 879 | </tr> |
| 880 | </tbody> |
| 881 | </table></div> |
| 882 | </div> |
| 883 | <hr> |
| 884 | <div class="refsect2"> |
| 885 | <a name="librdf-storage-get-arcs-in"></a><h3>librdf_storage_get_arcs_in ()</h3> |
| 886 | <pre class="programlisting"><a class="link" href="redland-iterator.html#librdf-iterator" title="librdf_iterator"><span class="returnvalue">librdf_iterator</span></a> * librdf_storage_get_arcs_in (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>, |
| 887 | <em class="parameter"><code><a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> *node</code></em>);</pre> |
| 888 | <p> |
| 889 | Return the properties pointing to the given resource. |
| 890 | </p> |
| 891 | <div class="variablelist"><table border="0"> |
| 892 | <col align="left" valign="top"> |
| 893 | <tbody> |
| 894 | <tr> |
| 895 | <td><p><span class="term"><em class="parameter"><code>storage</code></em> :</span></p></td> |
| 896 | <td> |
| 897 | <a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> object</td> |
| 898 | </tr> |
| 899 | <tr> |
| 900 | <td><p><span class="term"><em class="parameter"><code>node</code></em> :</span></p></td> |
| 901 | <td> |
| 902 | <a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> resource node</td> |
| 903 | </tr> |
| 904 | <tr> |
| 905 | <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td> |
| 906 | <td> |
| 907 | <a class="link" href="redland-iterator.html#librdf-iterator" title="librdf_iterator"><span class="type">librdf_iterator</span></a> of <a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> objects (may be empty) or NULL on failure</td> |
| 908 | </tr> |
| 909 | </tbody> |
| 910 | </table></div> |
| 911 | </div> |
| 912 | <hr> |
| 913 | <div class="refsect2"> |
| 914 | <a name="librdf-storage-get-arcs-out"></a><h3>librdf_storage_get_arcs_out ()</h3> |
| 915 | <pre class="programlisting"><a class="link" href="redland-iterator.html#librdf-iterator" title="librdf_iterator"><span class="returnvalue">librdf_iterator</span></a> * librdf_storage_get_arcs_out (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>, |
| 916 | <em class="parameter"><code><a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> *node</code></em>);</pre> |
| 917 | <p> |
| 918 | Return the properties pointing from the given resource. |
| 919 | </p> |
| 920 | <div class="variablelist"><table border="0"> |
| 921 | <col align="left" valign="top"> |
| 922 | <tbody> |
| 923 | <tr> |
| 924 | <td><p><span class="term"><em class="parameter"><code>storage</code></em> :</span></p></td> |
| 925 | <td> |
| 926 | <a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> object</td> |
| 927 | </tr> |
| 928 | <tr> |
| 929 | <td><p><span class="term"><em class="parameter"><code>node</code></em> :</span></p></td> |
| 930 | <td> |
| 931 | <a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> resource node</td> |
| 932 | </tr> |
| 933 | <tr> |
| 934 | <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td> |
| 935 | <td> |
| 936 | <a class="link" href="redland-iterator.html#librdf-iterator" title="librdf_iterator"><span class="type">librdf_iterator</span></a> of <a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> objects (may be empty) or NULL on failure</td> |
| 937 | </tr> |
| 938 | </tbody> |
| 939 | </table></div> |
| 940 | </div> |
| 941 | <hr> |
| 942 | <div class="refsect2"> |
| 943 | <a name="librdf-storage-has-arc-in"></a><h3>librdf_storage_has_arc_in ()</h3> |
| 944 | <pre class="programlisting"><span class="returnvalue">int</span> librdf_storage_has_arc_in (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>, |
| 945 | <em class="parameter"><code><a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> *node</code></em>, |
| 946 | <em class="parameter"><code><a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> *property</code></em>);</pre> |
| 947 | <p> |
| 948 | Check if a node has a given property pointing to it. |
| 949 | </p> |
| 950 | <div class="variablelist"><table border="0"> |
| 951 | <col align="left" valign="top"> |
| 952 | <tbody> |
| 953 | <tr> |
| 954 | <td><p><span class="term"><em class="parameter"><code>storage</code></em> :</span></p></td> |
| 955 | <td> |
| 956 | <a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> object</td> |
| 957 | </tr> |
| 958 | <tr> |
| 959 | <td><p><span class="term"><em class="parameter"><code>node</code></em> :</span></p></td> |
| 960 | <td> |
| 961 | <a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> resource node</td> |
| 962 | </tr> |
| 963 | <tr> |
| 964 | <td><p><span class="term"><em class="parameter"><code>property</code></em> :</span></p></td> |
| 965 | <td> |
| 966 | <a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> property node</td> |
| 967 | </tr> |
| 968 | <tr> |
| 969 | <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td> |
| 970 | <td>non 0 if arc property does point to the resource node</td> |
| 971 | </tr> |
| 972 | </tbody> |
| 973 | </table></div> |
| 974 | </div> |
| 975 | <hr> |
| 976 | <div class="refsect2"> |
| 977 | <a name="librdf-storage-has-arc-out"></a><h3>librdf_storage_has_arc_out ()</h3> |
| 978 | <pre class="programlisting"><span class="returnvalue">int</span> librdf_storage_has_arc_out (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>, |
| 979 | <em class="parameter"><code><a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> *node</code></em>, |
| 980 | <em class="parameter"><code><a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> *property</code></em>);</pre> |
| 981 | <p> |
| 982 | Check if a node has a given property pointing from it. |
| 983 | </p> |
| 984 | <div class="variablelist"><table border="0"> |
| 985 | <col align="left" valign="top"> |
| 986 | <tbody> |
| 987 | <tr> |
| 988 | <td><p><span class="term"><em class="parameter"><code>storage</code></em> :</span></p></td> |
| 989 | <td> |
| 990 | <a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> object</td> |
| 991 | </tr> |
| 992 | <tr> |
| 993 | <td><p><span class="term"><em class="parameter"><code>node</code></em> :</span></p></td> |
| 994 | <td> |
| 995 | <a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> resource node</td> |
| 996 | </tr> |
| 997 | <tr> |
| 998 | <td><p><span class="term"><em class="parameter"><code>property</code></em> :</span></p></td> |
| 999 | <td> |
| 1000 | <a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> property node</td> |
| 1001 | </tr> |
| 1002 | <tr> |
| 1003 | <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td> |
| 1004 | <td>non 0 if arc property does point from the resource node</td> |
| 1005 | </tr> |
| 1006 | </tbody> |
| 1007 | </table></div> |
| 1008 | </div> |
| 1009 | <hr> |
| 1010 | <div class="refsect2"> |
| 1011 | <a name="librdf-storage-context-add-statement"></a><h3>librdf_storage_context_add_statement ()</h3> |
| 1012 | <pre class="programlisting"><span class="returnvalue">int</span> librdf_storage_context_add_statement |
| 1013 | (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>, |
| 1014 | <em class="parameter"><code><a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> *context</code></em>, |
| 1015 | <em class="parameter"><code><a class="link" href="redland-statement.html#librdf-statement" title="librdf_statement"><span class="type">librdf_statement</span></a> *statement</code></em>);</pre> |
| 1016 | <p> |
| 1017 | Add a statement to a storage in a context. |
| 1018 | </p> |
| 1019 | <p> |
| 1020 | If <em class="parameter"><code>context</code></em> is NULL, this is equivalent to librdf_storage_add_statement |
| 1021 | </p> |
| 1022 | <div class="variablelist"><table border="0"> |
| 1023 | <col align="left" valign="top"> |
| 1024 | <tbody> |
| 1025 | <tr> |
| 1026 | <td><p><span class="term"><em class="parameter"><code>storage</code></em> :</span></p></td> |
| 1027 | <td> |
| 1028 | <a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> object</td> |
| 1029 | </tr> |
| 1030 | <tr> |
| 1031 | <td><p><span class="term"><em class="parameter"><code>context</code></em> :</span></p></td> |
| 1032 | <td> |
| 1033 | <a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> context node</td> |
| 1034 | </tr> |
| 1035 | <tr> |
| 1036 | <td><p><span class="term"><em class="parameter"><code>statement</code></em> :</span></p></td> |
| 1037 | <td> |
| 1038 | <a class="link" href="redland-statement.html#librdf-statement" title="librdf_statement"><span class="type">librdf_statement</span></a> statement to add</td> |
| 1039 | </tr> |
| 1040 | <tr> |
| 1041 | <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td> |
| 1042 | <td>non 0 on failure</td> |
| 1043 | </tr> |
| 1044 | </tbody> |
| 1045 | </table></div> |
| 1046 | </div> |
| 1047 | <hr> |
| 1048 | <div class="refsect2"> |
| 1049 | <a name="librdf-storage-context-add-statements"></a><h3>librdf_storage_context_add_statements ()</h3> |
| 1050 | <pre class="programlisting"><span class="returnvalue">int</span> librdf_storage_context_add_statements |
| 1051 | (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>, |
| 1052 | <em class="parameter"><code><a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> *context</code></em>, |
| 1053 | <em class="parameter"><code><a class="link" href="redland-stream.html#librdf-stream" title="librdf_stream"><span class="type">librdf_stream</span></a> *stream</code></em>);</pre> |
| 1054 | <p> |
| 1055 | Add statements to a storage with a context. |
| 1056 | </p> |
| 1057 | <p> |
| 1058 | If <em class="parameter"><code>context</code></em> is NULL, this is equivalent to librdf_storage_add_statements |
| 1059 | </p> |
| 1060 | <div class="variablelist"><table border="0"> |
| 1061 | <col align="left" valign="top"> |
| 1062 | <tbody> |
| 1063 | <tr> |
| 1064 | <td><p><span class="term"><em class="parameter"><code>storage</code></em> :</span></p></td> |
| 1065 | <td> |
| 1066 | <a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> object</td> |
| 1067 | </tr> |
| 1068 | <tr> |
| 1069 | <td><p><span class="term"><em class="parameter"><code>context</code></em> :</span></p></td> |
| 1070 | <td> |
| 1071 | <a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> context</td> |
| 1072 | </tr> |
| 1073 | <tr> |
| 1074 | <td><p><span class="term"><em class="parameter"><code>stream</code></em> :</span></p></td> |
| 1075 | <td> |
| 1076 | <a class="link" href="redland-stream.html#librdf-stream" title="librdf_stream"><span class="type">librdf_stream</span></a> stream object</td> |
| 1077 | </tr> |
| 1078 | <tr> |
| 1079 | <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td> |
| 1080 | <td>Non 0 on failure</td> |
| 1081 | </tr> |
| 1082 | </tbody> |
| 1083 | </table></div> |
| 1084 | </div> |
| 1085 | <hr> |
| 1086 | <div class="refsect2"> |
| 1087 | <a name="librdf-storage-context-remove-statement"></a><h3>librdf_storage_context_remove_statement ()</h3> |
| 1088 | <pre class="programlisting"><span class="returnvalue">int</span> librdf_storage_context_remove_statement |
| 1089 | (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>, |
| 1090 | <em class="parameter"><code><a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> *context</code></em>, |
| 1091 | <em class="parameter"><code><a class="link" href="redland-statement.html#librdf-statement" title="librdf_statement"><span class="type">librdf_statement</span></a> *statement</code></em>);</pre> |
| 1092 | <p> |
| 1093 | Remove a statement from a storage in a context. |
| 1094 | </p> |
| 1095 | <p> |
| 1096 | If <em class="parameter"><code>context</code></em> is NULL, this is equivalent to librdf_storage_remove_statement |
| 1097 | </p> |
| 1098 | <div class="variablelist"><table border="0"> |
| 1099 | <col align="left" valign="top"> |
| 1100 | <tbody> |
| 1101 | <tr> |
| 1102 | <td><p><span class="term"><em class="parameter"><code>storage</code></em> :</span></p></td> |
| 1103 | <td> |
| 1104 | <a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> object</td> |
| 1105 | </tr> |
| 1106 | <tr> |
| 1107 | <td><p><span class="term"><em class="parameter"><code>context</code></em> :</span></p></td> |
| 1108 | <td> |
| 1109 | <a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> context node</td> |
| 1110 | </tr> |
| 1111 | <tr> |
| 1112 | <td><p><span class="term"><em class="parameter"><code>statement</code></em> :</span></p></td> |
| 1113 | <td> |
| 1114 | <a class="link" href="redland-statement.html#librdf-statement" title="librdf_statement"><span class="type">librdf_statement</span></a> statement to remove</td> |
| 1115 | </tr> |
| 1116 | <tr> |
| 1117 | <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td> |
| 1118 | <td>non 0 on failure</td> |
| 1119 | </tr> |
| 1120 | </tbody> |
| 1121 | </table></div> |
| 1122 | </div> |
| 1123 | <hr> |
| 1124 | <div class="refsect2"> |
| 1125 | <a name="librdf-storage-context-remove-statements"></a><h3>librdf_storage_context_remove_statements ()</h3> |
| 1126 | <pre class="programlisting"><span class="returnvalue">int</span> librdf_storage_context_remove_statements |
| 1127 | (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>, |
| 1128 | <em class="parameter"><code><a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> *context</code></em>);</pre> |
| 1129 | <p> |
| 1130 | Remove statements from a storage with the given context. |
| 1131 | </p> |
| 1132 | <div class="variablelist"><table border="0"> |
| 1133 | <col align="left" valign="top"> |
| 1134 | <tbody> |
| 1135 | <tr> |
| 1136 | <td><p><span class="term"><em class="parameter"><code>storage</code></em> :</span></p></td> |
| 1137 | <td> |
| 1138 | <a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> object</td> |
| 1139 | </tr> |
| 1140 | <tr> |
| 1141 | <td><p><span class="term"><em class="parameter"><code>context</code></em> :</span></p></td> |
| 1142 | <td> |
| 1143 | <a class="link" href="redland-uri.html#librdf-uri" title="librdf_uri"><span class="type">librdf_uri</span></a> context</td> |
| 1144 | </tr> |
| 1145 | <tr> |
| 1146 | <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td> |
| 1147 | <td>Non 0 on failure</td> |
| 1148 | </tr> |
| 1149 | </tbody> |
| 1150 | </table></div> |
| 1151 | </div> |
| 1152 | <hr> |
| 1153 | <div class="refsect2"> |
| 1154 | <a name="librdf-storage-context-as-stream"></a><h3>librdf_storage_context_as_stream ()</h3> |
| 1155 | <pre class="programlisting"><a class="link" href="redland-stream.html#librdf-stream" title="librdf_stream"><span class="returnvalue">librdf_stream</span></a> * librdf_storage_context_as_stream (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>, |
| 1156 | <em class="parameter"><code><a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> *context</code></em>);</pre> |
| 1157 | <p> |
| 1158 | List all statements in a storage context. |
| 1159 | </p> |
| 1160 | <div class="variablelist"><table border="0"> |
| 1161 | <col align="left" valign="top"> |
| 1162 | <tbody> |
| 1163 | <tr> |
| 1164 | <td><p><span class="term"><em class="parameter"><code>storage</code></em> :</span></p></td> |
| 1165 | <td> |
| 1166 | <a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> object</td> |
| 1167 | </tr> |
| 1168 | <tr> |
| 1169 | <td><p><span class="term"><em class="parameter"><code>context</code></em> :</span></p></td> |
| 1170 | <td> |
| 1171 | <a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> context node</td> |
| 1172 | </tr> |
| 1173 | <tr> |
| 1174 | <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td> |
| 1175 | <td> |
| 1176 | <a class="link" href="redland-stream.html#librdf-stream" title="librdf_stream"><span class="type">librdf_stream</span></a> of statements or NULL on failure or context is empty</td> |
| 1177 | </tr> |
| 1178 | </tbody> |
| 1179 | </table></div> |
| 1180 | </div> |
| 1181 | <hr> |
| 1182 | <div class="refsect2"> |
| 1183 | <a name="librdf-storage-context-serialise"></a><h3>librdf_storage_context_serialise ()</h3> |
| 1184 | <pre class="programlisting"><a class="link" href="redland-stream.html#librdf-stream" title="librdf_stream"><span class="returnvalue">librdf_stream</span></a> * librdf_storage_context_serialise (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>, |
| 1185 | <em class="parameter"><code><a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> *context</code></em>);</pre> |
| 1186 | <p> |
| 1187 | List all statements in a storage context (DEPRECATED). |
| 1188 | </p> |
| 1189 | <p> |
| 1190 | DEPRECATED to reduce confusion with the librdf_serializer class. |
| 1191 | Please use librdf_storage_context_as_stream. |
| 1192 | </p> |
| 1193 | <div class="variablelist"><table border="0"> |
| 1194 | <col align="left" valign="top"> |
| 1195 | <tbody> |
| 1196 | <tr> |
| 1197 | <td><p><span class="term"><em class="parameter"><code>storage</code></em> :</span></p></td> |
| 1198 | <td> |
| 1199 | <a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> object</td> |
| 1200 | </tr> |
| 1201 | <tr> |
| 1202 | <td><p><span class="term"><em class="parameter"><code>context</code></em> :</span></p></td> |
| 1203 | <td> |
| 1204 | <a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> context node</td> |
| 1205 | </tr> |
| 1206 | <tr> |
| 1207 | <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td> |
| 1208 | <td> |
| 1209 | <a class="link" href="redland-stream.html#librdf-stream" title="librdf_stream"><span class="type">librdf_stream</span></a> of statements or NULL on failure or context is empty</td> |
| 1210 | </tr> |
| 1211 | </tbody> |
| 1212 | </table></div> |
| 1213 | </div> |
| 1214 | <hr> |
| 1215 | <div class="refsect2"> |
| 1216 | <a name="librdf-storage-supports-query"></a><h3>librdf_storage_supports_query ()</h3> |
| 1217 | <pre class="programlisting"><span class="returnvalue">int</span> librdf_storage_supports_query (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>, |
| 1218 | <em class="parameter"><code><a class="link" href="redland-query.html#librdf-query" title="librdf_query"><span class="type">librdf_query</span></a> *query</code></em>);</pre> |
| 1219 | <p> |
| 1220 | Check if a storage system supports a query language. |
| 1221 | </p> |
| 1222 | <div class="variablelist"><table border="0"> |
| 1223 | <col align="left" valign="top"> |
| 1224 | <tbody> |
| 1225 | <tr> |
| 1226 | <td><p><span class="term"><em class="parameter"><code>storage</code></em> :</span></p></td> |
| 1227 | <td> |
| 1228 | <a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> object</td> |
| 1229 | </tr> |
| 1230 | <tr> |
| 1231 | <td><p><span class="term"><em class="parameter"><code>query</code></em> :</span></p></td> |
| 1232 | <td> |
| 1233 | <a class="link" href="redland-query.html#librdf-query" title="librdf_query"><span class="type">librdf_query</span></a> query object</td> |
| 1234 | </tr> |
| 1235 | <tr> |
| 1236 | <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td> |
| 1237 | <td>non-0 if the query is supported.</td> |
| 1238 | </tr> |
| 1239 | </tbody> |
| 1240 | </table></div> |
| 1241 | </div> |
| 1242 | <hr> |
| 1243 | <div class="refsect2"> |
| 1244 | <a name="librdf-storage-query-execute"></a><h3>librdf_storage_query_execute ()</h3> |
| 1245 | <pre class="programlisting"><a class="link" href="redland-query-results.html#librdf-query-results" title="librdf_query_results"><span class="returnvalue">librdf_query_results</span></a> * librdf_storage_query_execute (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>, |
| 1246 | <em class="parameter"><code><a class="link" href="redland-query.html#librdf-query" title="librdf_query"><span class="type">librdf_query</span></a> *query</code></em>);</pre> |
| 1247 | <p> |
| 1248 | Run the given query against the storage. |
| 1249 | </p> |
| 1250 | <p> |
| 1251 | Not implemented. |
| 1252 | </p> |
| 1253 | <div class="variablelist"><table border="0"> |
| 1254 | <col align="left" valign="top"> |
| 1255 | <tbody> |
| 1256 | <tr> |
| 1257 | <td><p><span class="term"><em class="parameter"><code>storage</code></em> :</span></p></td> |
| 1258 | <td> |
| 1259 | <a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> object</td> |
| 1260 | </tr> |
| 1261 | <tr> |
| 1262 | <td><p><span class="term"><em class="parameter"><code>query</code></em> :</span></p></td> |
| 1263 | <td> |
| 1264 | <a class="link" href="redland-query.html#librdf-query" title="librdf_query"><span class="type">librdf_query</span></a> query object</td> |
| 1265 | </tr> |
| 1266 | <tr> |
| 1267 | <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td> |
| 1268 | <td> |
| 1269 | <a class="link" href="redland-query-results.html#librdf-query-results" title="librdf_query_results"><span class="type">librdf_query_results</span></a> or NULL on failure</td> |
| 1270 | </tr> |
| 1271 | </tbody> |
| 1272 | </table></div> |
| 1273 | </div> |
| 1274 | <hr> |
| 1275 | <div class="refsect2"> |
| 1276 | <a name="librdf-storage-sync"></a><h3>librdf_storage_sync ()</h3> |
| 1277 | <pre class="programlisting"><span class="returnvalue">int</span> librdf_storage_sync (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>);</pre> |
| 1278 | <p> |
| 1279 | Synchronise the storage to the storage implementation. |
| 1280 | </p> |
| 1281 | <div class="variablelist"><table border="0"> |
| 1282 | <col align="left" valign="top"> |
| 1283 | <tbody> |
| 1284 | <tr> |
| 1285 | <td><p><span class="term"><em class="parameter"><code>storage</code></em> :</span></p></td> |
| 1286 | <td> |
| 1287 | <a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> object</td> |
| 1288 | </tr> |
| 1289 | <tr> |
| 1290 | <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td> |
| 1291 | <td>non-0 on failure</td> |
| 1292 | </tr> |
| 1293 | </tbody> |
| 1294 | </table></div> |
| 1295 | </div> |
| 1296 | <hr> |
| 1297 | <div class="refsect2"> |
| 1298 | <a name="librdf-storage-find-statements-in-context"></a><h3>librdf_storage_find_statements_in_context ()</h3> |
| 1299 | <pre class="programlisting"><a class="link" href="redland-stream.html#librdf-stream" title="librdf_stream"><span class="returnvalue">librdf_stream</span></a> * librdf_storage_find_statements_in_context |
| 1300 | (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>, |
| 1301 | <em class="parameter"><code><a class="link" href="redland-statement.html#librdf-statement" title="librdf_statement"><span class="type">librdf_statement</span></a> *statement</code></em>, |
| 1302 | <em class="parameter"><code><a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> *context_node</code></em>);</pre> |
| 1303 | <p> |
| 1304 | Search the storage for matching statements in a given context. |
| 1305 | </p> |
| 1306 | <p> |
| 1307 | Searches the storage for a (partial) statement as described in |
| 1308 | <a class="link" href="redland-statement.html#librdf-statement-match" title="librdf_statement_match ()"><code class="function">librdf_statement_match()</code></a> in the given context and returns a |
| 1309 | <a class="link" href="redland-stream.html#librdf-stream" title="librdf_stream"><span class="type">librdf_stream</span></a> of matching <a class="link" href="redland-statement.html#librdf-statement" title="librdf_statement"><span class="type">librdf_statement</span></a> objects. If |
| 1310 | context is NULL, this is equivalent to librdf_storage_find_statements. |
| 1311 | </p> |
| 1312 | <div class="variablelist"><table border="0"> |
| 1313 | <col align="left" valign="top"> |
| 1314 | <tbody> |
| 1315 | <tr> |
| 1316 | <td><p><span class="term"><em class="parameter"><code>storage</code></em> :</span></p></td> |
| 1317 | <td> |
| 1318 | <a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> object</td> |
| 1319 | </tr> |
| 1320 | <tr> |
| 1321 | <td><p><span class="term"><em class="parameter"><code>statement</code></em> :</span></p></td> |
| 1322 | <td> |
| 1323 | <a class="link" href="redland-statement.html#librdf-statement" title="librdf_statement"><span class="type">librdf_statement</span></a> partial statement to find</td> |
| 1324 | </tr> |
| 1325 | <tr> |
| 1326 | <td><p><span class="term"><em class="parameter"><code>context_node</code></em> :</span></p></td> |
| 1327 | <td>context <a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> (or NULL)</td> |
| 1328 | </tr> |
| 1329 | <tr> |
| 1330 | <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td> |
| 1331 | <td> |
| 1332 | <a class="link" href="redland-stream.html#librdf-stream" title="librdf_stream"><span class="type">librdf_stream</span></a> of matching statements (may be empty) or NULL on failure</td> |
| 1333 | </tr> |
| 1334 | </tbody> |
| 1335 | </table></div> |
| 1336 | </div> |
| 1337 | <hr> |
| 1338 | <div class="refsect2"> |
| 1339 | <a name="librdf-storage-get-contexts"></a><h3>librdf_storage_get_contexts ()</h3> |
| 1340 | <pre class="programlisting"><a class="link" href="redland-iterator.html#librdf-iterator" title="librdf_iterator"><span class="returnvalue">librdf_iterator</span></a> * librdf_storage_get_contexts (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>);</pre> |
| 1341 | <p> |
| 1342 | Return the list of contexts in the store. |
| 1343 | </p> |
| 1344 | <p> |
| 1345 | Returns an iterator of <a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> context nodes for each |
| 1346 | context in the store. |
| 1347 | </p> |
| 1348 | <div class="variablelist"><table border="0"> |
| 1349 | <col align="left" valign="top"> |
| 1350 | <tbody> |
| 1351 | <tr> |
| 1352 | <td><p><span class="term"><em class="parameter"><code>storage</code></em> :</span></p></td> |
| 1353 | <td> |
| 1354 | <a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> object</td> |
| 1355 | </tr> |
| 1356 | <tr> |
| 1357 | <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td> |
| 1358 | <td> |
| 1359 | <a class="link" href="redland-iterator.html#librdf-iterator" title="librdf_iterator"><span class="type">librdf_iterator</span></a> of context nodes or NULL on failure or if contexts are not supported</td> |
| 1360 | </tr> |
| 1361 | </tbody> |
| 1362 | </table></div> |
| 1363 | </div> |
| 1364 | <hr> |
| 1365 | <div class="refsect2"> |
| 1366 | <a name="librdf-storage-get-feature"></a><h3>librdf_storage_get_feature ()</h3> |
| 1367 | <pre class="programlisting"><a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="returnvalue">librdf_node</span></a> * librdf_storage_get_feature (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>, |
| 1368 | <em class="parameter"><code><a class="link" href="redland-uri.html#librdf-uri" title="librdf_uri"><span class="type">librdf_uri</span></a> *feature</code></em>);</pre> |
| 1369 | <p> |
| 1370 | Get the value of a storage feature. |
| 1371 | </p> |
| 1372 | <div class="variablelist"><table border="0"> |
| 1373 | <col align="left" valign="top"> |
| 1374 | <tbody> |
| 1375 | <tr> |
| 1376 | <td><p><span class="term"><em class="parameter"><code>storage</code></em> :</span></p></td> |
| 1377 | <td> |
| 1378 | <a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> object</td> |
| 1379 | </tr> |
| 1380 | <tr> |
| 1381 | <td><p><span class="term"><em class="parameter"><code>feature</code></em> :</span></p></td> |
| 1382 | <td> |
| 1383 | <a class="link" href="redland-uri.html#librdf-uri" title="librdf_uri"><span class="type">librdf_uri</span></a> feature property</td> |
| 1384 | </tr> |
| 1385 | <tr> |
| 1386 | <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td> |
| 1387 | <td>new <a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> feature value or NULL if no such feature |
| 1388 | exists or the value is empty.</td> |
| 1389 | </tr> |
| 1390 | </tbody> |
| 1391 | </table></div> |
| 1392 | </div> |
| 1393 | <hr> |
| 1394 | <div class="refsect2"> |
| 1395 | <a name="librdf-storage-set-feature"></a><h3>librdf_storage_set_feature ()</h3> |
| 1396 | <pre class="programlisting"><span class="returnvalue">int</span> librdf_storage_set_feature (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>, |
| 1397 | <em class="parameter"><code><a class="link" href="redland-uri.html#librdf-uri" title="librdf_uri"><span class="type">librdf_uri</span></a> *feature</code></em>, |
| 1398 | <em class="parameter"><code><a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> *value</code></em>);</pre> |
| 1399 | <p> |
| 1400 | Set the value of a storage feature. |
| 1401 | </p> |
| 1402 | <div class="variablelist"><table border="0"> |
| 1403 | <col align="left" valign="top"> |
| 1404 | <tbody> |
| 1405 | <tr> |
| 1406 | <td><p><span class="term"><em class="parameter"><code>storage</code></em> :</span></p></td> |
| 1407 | <td> |
| 1408 | <a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> object</td> |
| 1409 | </tr> |
| 1410 | <tr> |
| 1411 | <td><p><span class="term"><em class="parameter"><code>feature</code></em> :</span></p></td> |
| 1412 | <td> |
| 1413 | <a class="link" href="redland-uri.html#librdf-uri" title="librdf_uri"><span class="type">librdf_uri</span></a> feature property</td> |
| 1414 | </tr> |
| 1415 | <tr> |
| 1416 | <td><p><span class="term"><em class="parameter"><code>value</code></em> :</span></p></td> |
| 1417 | <td> |
| 1418 | <a class="link" href="redland-node.html#librdf-node" title="librdf_node"><span class="type">librdf_node</span></a> feature property value</td> |
| 1419 | </tr> |
| 1420 | <tr> |
| 1421 | <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td> |
| 1422 | <td>non 0 on failure (negative if no such feature)</td> |
| 1423 | </tr> |
| 1424 | </tbody> |
| 1425 | </table></div> |
| 1426 | </div> |
| 1427 | <hr> |
| 1428 | <div class="refsect2"> |
| 1429 | <a name="librdf-storage-transaction-commit"></a><h3>librdf_storage_transaction_commit ()</h3> |
| 1430 | <pre class="programlisting"><span class="returnvalue">int</span> librdf_storage_transaction_commit (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>);</pre> |
| 1431 | <p> |
| 1432 | Commit a transaction. |
| 1433 | </p> |
| 1434 | <div class="variablelist"><table border="0"> |
| 1435 | <col align="left" valign="top"> |
| 1436 | <tbody> |
| 1437 | <tr> |
| 1438 | <td><p><span class="term"><em class="parameter"><code>storage</code></em> :</span></p></td> |
| 1439 | <td>the storage object</td> |
| 1440 | </tr> |
| 1441 | <tr> |
| 1442 | <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td> |
| 1443 | <td>non-0 on failure</td> |
| 1444 | </tr> |
| 1445 | </tbody> |
| 1446 | </table></div> |
| 1447 | </div> |
| 1448 | <hr> |
| 1449 | <div class="refsect2"> |
| 1450 | <a name="librdf-storage-transaction-get-handle"></a><h3>librdf_storage_transaction_get_handle ()</h3> |
| 1451 | <pre class="programlisting"><span class="returnvalue">void</span> * librdf_storage_transaction_get_handle |
| 1452 | (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>);</pre> |
| 1453 | <p> |
| 1454 | Get the current transaction handle. |
| 1455 | </p> |
| 1456 | <div class="variablelist"><table border="0"> |
| 1457 | <col align="left" valign="top"> |
| 1458 | <tbody> |
| 1459 | <tr> |
| 1460 | <td><p><span class="term"><em class="parameter"><code>storage</code></em> :</span></p></td> |
| 1461 | <td>the storage object</td> |
| 1462 | </tr> |
| 1463 | <tr> |
| 1464 | <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td> |
| 1465 | <td>non-0 on failure</td> |
| 1466 | </tr> |
| 1467 | </tbody> |
| 1468 | </table></div> |
| 1469 | </div> |
| 1470 | <hr> |
| 1471 | <div class="refsect2"> |
| 1472 | <a name="librdf-storage-transaction-rollback"></a><h3>librdf_storage_transaction_rollback ()</h3> |
| 1473 | <pre class="programlisting"><span class="returnvalue">int</span> librdf_storage_transaction_rollback (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>);</pre> |
| 1474 | <p> |
| 1475 | Rollback a transaction. |
| 1476 | </p> |
| 1477 | <div class="variablelist"><table border="0"> |
| 1478 | <col align="left" valign="top"> |
| 1479 | <tbody> |
| 1480 | <tr> |
| 1481 | <td><p><span class="term"><em class="parameter"><code>storage</code></em> :</span></p></td> |
| 1482 | <td>the storage object</td> |
| 1483 | </tr> |
| 1484 | <tr> |
| 1485 | <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td> |
| 1486 | <td>non-0 on failure</td> |
| 1487 | </tr> |
| 1488 | </tbody> |
| 1489 | </table></div> |
| 1490 | </div> |
| 1491 | <hr> |
| 1492 | <div class="refsect2"> |
| 1493 | <a name="librdf-storage-transaction-start"></a><h3>librdf_storage_transaction_start ()</h3> |
| 1494 | <pre class="programlisting"><span class="returnvalue">int</span> librdf_storage_transaction_start (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>);</pre> |
| 1495 | <p> |
| 1496 | Start a transaction |
| 1497 | </p> |
| 1498 | <div class="variablelist"><table border="0"> |
| 1499 | <col align="left" valign="top"> |
| 1500 | <tbody> |
| 1501 | <tr> |
| 1502 | <td><p><span class="term"><em class="parameter"><code>storage</code></em> :</span></p></td> |
| 1503 | <td>the storage object</td> |
| 1504 | </tr> |
| 1505 | <tr> |
| 1506 | <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td> |
| 1507 | <td>non-0 on failure</td> |
| 1508 | </tr> |
| 1509 | </tbody> |
| 1510 | </table></div> |
| 1511 | </div> |
| 1512 | <hr> |
| 1513 | <div class="refsect2"> |
| 1514 | <a name="librdf-storage-transaction-start-with-handle"></a><h3>librdf_storage_transaction_start_with_handle ()</h3> |
| 1515 | <pre class="programlisting"><span class="returnvalue">int</span> librdf_storage_transaction_start_with_handle |
| 1516 | (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>, |
| 1517 | <em class="parameter"><code><span class="type">void</span> *handle</code></em>);</pre> |
| 1518 | <p> |
| 1519 | Start a transaction using an existing external transaction object. |
| 1520 | </p> |
| 1521 | <div class="variablelist"><table border="0"> |
| 1522 | <col align="left" valign="top"> |
| 1523 | <tbody> |
| 1524 | <tr> |
| 1525 | <td><p><span class="term"><em class="parameter"><code>storage</code></em> :</span></p></td> |
| 1526 | <td>the storage object</td> |
| 1527 | </tr> |
| 1528 | <tr> |
| 1529 | <td><p><span class="term"><em class="parameter"><code>handle</code></em> :</span></p></td> |
| 1530 | <td>the transaction object</td> |
| 1531 | </tr> |
| 1532 | <tr> |
| 1533 | <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td> |
| 1534 | <td>non-0 on failure</td> |
| 1535 | </tr> |
| 1536 | </tbody> |
| 1537 | </table></div> |
| 1538 | </div> |
| 1539 | <hr> |
| 1540 | <div class="refsect2"> |
| 1541 | <a name="librdf-storage-add-reference"></a><h3>librdf_storage_add_reference ()</h3> |
| 1542 | <pre class="programlisting"><span class="returnvalue">void</span> librdf_storage_add_reference (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>);</pre> |
| 1543 | <p> |
| 1544 | Increment storage reference count by one. |
| 1545 | </p> |
| 1546 | <p> |
| 1547 | This function is intended to be internal to librdf storage modules. |
| 1548 | </p> |
| 1549 | <div class="variablelist"><table border="0"> |
| 1550 | <col align="left" valign="top"> |
| 1551 | <tbody><tr> |
| 1552 | <td><p><span class="term"><em class="parameter"><code>storage</code></em> :</span></p></td> |
| 1553 | <td> |
| 1554 | <a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> object</td> |
| 1555 | </tr></tbody> |
| 1556 | </table></div> |
| 1557 | </div> |
| 1558 | <hr> |
| 1559 | <div class="refsect2"> |
| 1560 | <a name="librdf-storage-remove-reference"></a><h3>librdf_storage_remove_reference ()</h3> |
| 1561 | <pre class="programlisting"><span class="returnvalue">void</span> librdf_storage_remove_reference (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>);</pre> |
| 1562 | <p> |
| 1563 | Decrement storage reference count by one and free the storage if reference count becomes zero. |
| 1564 | </p> |
| 1565 | <p> |
| 1566 | This function is intended to be internal to librdf storage modules. |
| 1567 | </p> |
| 1568 | <div class="variablelist"><table border="0"> |
| 1569 | <col align="left" valign="top"> |
| 1570 | <tbody><tr> |
| 1571 | <td><p><span class="term"><em class="parameter"><code>storage</code></em> :</span></p></td> |
| 1572 | <td> |
| 1573 | <a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> object</td> |
| 1574 | </tr></tbody> |
| 1575 | </table></div> |
| 1576 | </div> |
| 1577 | <hr> |
| 1578 | <div class="refsect2"> |
| 1579 | <a name="librdf-storage-instance"></a><h3>librdf_storage_instance</h3> |
| 1580 | <pre class="programlisting">typedef void* librdf_storage_instance; |
| 1581 | </pre> |
| 1582 | <p> |
| 1583 | Opaque storage module instance handle. |
| 1584 | </p> |
| 1585 | <p> |
| 1586 | For use with a storage module and the <a class="link" href="redland-storage.html#librdf-storage-get-instance" title="librdf_storage_get_instance ()"><code class="function">librdf_storage_get_instance()</code></a> |
| 1587 | and <a class="link" href="redland-storage.html#librdf-storage-set-instance" title="librdf_storage_set_instance ()"><code class="function">librdf_storage_set_instance()</code></a> functions. The instance handle |
| 1588 | should be set in the <a class="link" href="redland-storage.html#librdf-storage-factory" title="librdf_storage_factory"><span class="type">librdf_storage_factory</span></a> init factory method. |
| 1589 | </p> |
| 1590 | </div> |
| 1591 | <hr> |
| 1592 | <div class="refsect2"> |
| 1593 | <a name="librdf-storage-get-instance"></a><h3>librdf_storage_get_instance ()</h3> |
| 1594 | <pre class="programlisting"><a class="link" href="redland-storage.html#librdf-storage-instance" title="librdf_storage_instance"><span class="returnvalue">librdf_storage_instance</span></a> librdf_storage_get_instance (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>);</pre> |
| 1595 | <p> |
| 1596 | Get instance data for this storage |
| 1597 | </p> |
| 1598 | <div class="variablelist"><table border="0"> |
| 1599 | <col align="left" valign="top"> |
| 1600 | <tbody> |
| 1601 | <tr> |
| 1602 | <td><p><span class="term"><em class="parameter"><code>storage</code></em> :</span></p></td> |
| 1603 | <td> |
| 1604 | <a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> object</td> |
| 1605 | </tr> |
| 1606 | <tr> |
| 1607 | <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td> |
| 1608 | <td>opaque instance data for this storage</td> |
| 1609 | </tr> |
| 1610 | </tbody> |
| 1611 | </table></div> |
| 1612 | </div> |
| 1613 | <hr> |
| 1614 | <div class="refsect2"> |
| 1615 | <a name="librdf-storage-set-instance"></a><h3>librdf_storage_set_instance ()</h3> |
| 1616 | <pre class="programlisting"><span class="returnvalue">void</span> librdf_storage_set_instance (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>, |
| 1617 | <em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage-instance" title="librdf_storage_instance"><span class="type">librdf_storage_instance</span></a> instance</code></em>);</pre> |
| 1618 | <p> |
| 1619 | Set the instance data for this storage. |
| 1620 | </p> |
| 1621 | <p> |
| 1622 | This function is intended for use by the 'init' method of storage |
| 1623 | implementations to set instance data which can be retrived with |
| 1624 | <a class="link" href="redland-storage.html#librdf-storage-get-instance" title="librdf_storage_get_instance ()"><code class="function">librdf_storage_get_instance()</code></a> and used in other methods of that |
| 1625 | storage. |
| 1626 | </p> |
| 1627 | <p> |
| 1628 | The instance is completely opaque to librdf, including allocation |
| 1629 | and deallocation. |
| 1630 | </p> |
| 1631 | <div class="variablelist"><table border="0"> |
| 1632 | <col align="left" valign="top"> |
| 1633 | <tbody> |
| 1634 | <tr> |
| 1635 | <td><p><span class="term"><em class="parameter"><code>storage</code></em> :</span></p></td> |
| 1636 | <td> |
| 1637 | <a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> object</td> |
| 1638 | </tr> |
| 1639 | <tr> |
| 1640 | <td><p><span class="term"><em class="parameter"><code>instance</code></em> :</span></p></td> |
| 1641 | <td>Opaque instance pointer</td> |
| 1642 | </tr> |
| 1643 | </tbody> |
| 1644 | </table></div> |
| 1645 | </div> |
| 1646 | <hr> |
| 1647 | <div class="refsect2"> |
| 1648 | <a name="librdf-storage-get-world"></a><h3>librdf_storage_get_world ()</h3> |
| 1649 | <pre class="programlisting"><a class="link" href="redland-world.html#librdf-world" title="librdf_world"><span class="returnvalue">librdf_world</span></a> * librdf_storage_get_world (<em class="parameter"><code><a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> *storage</code></em>);</pre> |
| 1650 | <p> |
| 1651 | Get the <a class="link" href="redland-world.html#librdf-world" title="librdf_world"><span class="type">librdf_world</span></a> object associated with this storage. |
| 1652 | </p> |
| 1653 | <div class="variablelist"><table border="0"> |
| 1654 | <col align="left" valign="top"> |
| 1655 | <tbody> |
| 1656 | <tr> |
| 1657 | <td><p><span class="term"><em class="parameter"><code>storage</code></em> :</span></p></td> |
| 1658 | <td> |
| 1659 | <a class="link" href="redland-storage.html#librdf-storage" title="librdf_storage"><span class="type">librdf_storage</span></a> object</td> |
| 1660 | </tr> |
| 1661 | <tr> |
| 1662 | <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td> |
| 1663 | <td>world object for this storage</td> |
| 1664 | </tr> |
| 1665 | </tbody> |
| 1666 | </table></div> |
| 1667 | </div> |
| 1668 | <hr> |
| 1669 | <div class="refsect2"> |
| 1670 | <a name="librdf-storage-module-register-function"></a><h3>librdf_storage_module_register_function ()</h3> |
| 1671 | <pre class="programlisting"><span class="returnvalue">void</span> (*librdf_storage_module_register_function) |
| 1672 | (<em class="parameter"><code><a class="link" href="redland-world.html#librdf-world" title="librdf_world"><span class="type">librdf_world</span></a> *world</code></em>);</pre> |
| 1673 | <p> |
| 1674 | Registration function for storage |
| 1675 | </p> |
| 1676 | <p> |
| 1677 | A storage module must define and export a function named of this |
| 1678 | type with function name "librdf_storage_module_register_factory". |
| 1679 | </p> |
| 1680 | <p> |
| 1681 | This function will be called by Redland and must call |
| 1682 | <a class="link" href="redland-storage.html#librdf-storage-register-factory" title="librdf_storage_register_factory ()"><code class="function">librdf_storage_register_factory()</code></a> to register whatever storage |
| 1683 | backends are implemented in the module. |
| 1684 | </p> |
| 1685 | <div class="variablelist"><table border="0"> |
| 1686 | <col align="left" valign="top"> |
| 1687 | <tbody><tr> |
| 1688 | <td><p><span class="term"><em class="parameter"><code>world</code></em> :</span></p></td> |
| 1689 | <td>world object</td> |
| 1690 | </tr></tbody> |
| 1691 | </table></div> |
| 1692 | </div> |
| 1693 | </div> |
| 1694 | </div> |
| 1695 | <div class="footer"> |
| 1696 | <hr> |
| 1697 | Generated by GTK-Doc V1.18</div> |
| 1698 | </body> |
| 1699 | </html> |