summaryrefslogtreecommitdiffstats
path: root/lilv
diff options
context:
space:
mode:
Diffstat (limited to 'lilv')
-rw-r--r--lilv/lilv.h33
-rw-r--r--lilv/lilvmm.hpp7
2 files changed, 16 insertions, 24 deletions
diff --git a/lilv/lilv.h b/lilv/lilv.h
index fbb7207..0d0eec4 100644
--- a/lilv/lilv.h
+++ b/lilv/lilv.h
@@ -609,6 +609,18 @@ const LilvPlugins*
lilv_world_get_all_plugins(const LilvWorld* world);
/**
+ Find nodes matching a triple pattern.
+ Either @c subject or @c object may be NULL (i.e. a wildcard), but not both.
+ @return All matches for the wildcard field, or NULL.
+*/
+LILV_API
+LilvNodes*
+lilv_world_find_nodes(LilvWorld* world,
+ const LilvNode* subject,
+ const LilvNode* predicate,
+ const LilvNode* object);
+
+/**
@}
@name Plugin
@{
@@ -719,27 +731,6 @@ lilv_plugin_get_value(const LilvPlugin* p,
const LilvNode* predicate);
/**
- Get a value associated with some subject in a plugin's data files.
- @a predicate must be either a URI or a QName.
-
- Returns the ?object of all triples found of the form:
-
- <code>subject predicate ?object</code>
-
- This can be used to investigate URIs returned by lilv_plugin_get_value
- (if information about it is contained in the plugin's data files).
-
- May return NULL if the property was not found, or if object is not
- sensibly represented as an LilvNodes (e.g. blank nodes).
- Return value must be freed by caller with lilv_nodes_free.
-*/
-LILV_API
-LilvNodes*
-lilv_plugin_get_value_for_subject(const LilvPlugin* p,
- const LilvNode* subject_uri,
- const LilvNode* predicate_uri);
-
-/**
Return whether a feature is supported by a plugin.
This will return true if the feature is an optional or required feature
of the plugin.
diff --git a/lilv/lilvmm.hpp b/lilv/lilvmm.hpp
index d0bd1cd..5fb51af 100644
--- a/lilv/lilvmm.hpp
+++ b/lilv/lilvmm.hpp
@@ -146,7 +146,10 @@ struct World {
inline LilvNode* new_bool(bool val) {
return lilv_new_bool(me, val);
}
-
+ LILV_WRAP2(Nodes, world, find_nodes,
+ Node, subject,
+ Node, predicate,
+ Node, object);
LILV_WRAP2_VOID(world, set_option, const char*, uri, LilvNode*, value);
LILV_WRAP0_VOID(world, free);
LILV_WRAP0_VOID(world, load_all);
@@ -199,8 +202,6 @@ struct Plugin {
LILV_WRAP0(Node, plugin, get_name);
LILV_WRAP0(PluginClass, plugin, get_class);
LILV_WRAP1(Nodes, plugin, get_value, Node, pred);
- LILV_WRAP2(Nodes, plugin, get_value_for_subject, Node, subject,
- Node, predicate);
LILV_WRAP1(bool, plugin, has_feature, Node, feature_uri);
LILV_WRAP0(Nodes, plugin, get_supported_features);
LILV_WRAP0(Nodes, plugin, get_required_features);