summaryrefslogtreecommitdiffstats
path: root/lilv/lilvmm.hpp
diff options
context:
space:
mode:
Diffstat (limited to 'lilv/lilvmm.hpp')
-rw-r--r--lilv/lilvmm.hpp130
1 files changed, 65 insertions, 65 deletions
diff --git a/lilv/lilvmm.hpp b/lilv/lilvmm.hpp
index b2fe293..9a256b0 100644
--- a/lilv/lilvmm.hpp
+++ b/lilv/lilvmm.hpp
@@ -48,44 +48,44 @@ const char* uri_to_path(const char* uri) { return lilv_uri_to_path(uri); }
#define LILV_WRAP_CONVERSION(CT)
#endif
-struct Value {
- inline Value(const LilvValue* value) : me(lilv_value_duplicate(value)) {}
- inline Value(const Value& copy) : me(lilv_value_duplicate(copy.me)) {}
+struct Node {
+ inline Node(const LilvNode* node) : me(lilv_node_duplicate(node)) {}
+ inline Node(const Node& copy) : me(lilv_node_duplicate(copy.me)) {}
- inline ~Value() { lilv_value_free(me); }
+ inline ~Node() { lilv_node_free(me); }
- inline bool equals(const Value& other) const {
- return lilv_value_equals(me, other.me);
+ inline bool equals(const Node& other) const {
+ return lilv_node_equals(me, other.me);
}
- inline bool operator==(const Value& other) const { return equals(other); }
-
- LILV_WRAP_CONVERSION(LilvValue);
-
- LILV_WRAP0(char*, value, get_turtle_token);
- LILV_WRAP0(bool, value, is_uri);
- LILV_WRAP0(const char*, value, as_uri);
- LILV_WRAP0(bool, value, is_blank);
- LILV_WRAP0(const char*, value, as_blank);
- LILV_WRAP0(bool, value, is_literal);
- LILV_WRAP0(bool, value, is_string);
- LILV_WRAP0(const char*, value, as_string);
- LILV_WRAP0(bool, value, is_float);
- LILV_WRAP0(float, value, as_float);
- LILV_WRAP0(bool, value, is_int);
- LILV_WRAP0(int, value, as_int);
- LILV_WRAP0(bool, value, is_bool);
- LILV_WRAP0(bool, value, as_bool);
-
- LilvValue* me;
+ inline bool operator==(const Node& other) const { return equals(other); }
+
+ LILV_WRAP_CONVERSION(LilvNode);
+
+ LILV_WRAP0(char*, node, get_turtle_token);
+ LILV_WRAP0(bool, node, is_uri);
+ LILV_WRAP0(const char*, node, as_uri);
+ LILV_WRAP0(bool, node, is_blank);
+ LILV_WRAP0(const char*, node, as_blank);
+ LILV_WRAP0(bool, node, is_literal);
+ LILV_WRAP0(bool, node, is_string);
+ LILV_WRAP0(const char*, node, as_string);
+ LILV_WRAP0(bool, node, is_float);
+ LILV_WRAP0(float, node, as_float);
+ LILV_WRAP0(bool, node, is_int);
+ LILV_WRAP0(int, node, as_int);
+ LILV_WRAP0(bool, node, is_bool);
+ LILV_WRAP0(bool, node, as_bool);
+
+ LilvNode* me;
};
struct ScalePoint {
inline ScalePoint(const LilvScalePoint* c_obj) : me(c_obj) {}
LILV_WRAP_CONVERSION(const LilvScalePoint);
- LILV_WRAP0(const LilvValue*, scale_point, get_label);
- LILV_WRAP0(const LilvValue*, scale_point, get_value);
+ LILV_WRAP0(const LilvNode*, scale_point, get_label);
+ LILV_WRAP0(const LilvNode*, scale_point, get_value);
const LilvScalePoint* me;
};
@@ -94,9 +94,9 @@ struct PluginClass {
inline PluginClass(const LilvPluginClass* c_obj) : me(c_obj) {}
LILV_WRAP_CONVERSION(const LilvPluginClass);
- LILV_WRAP0(Value, plugin_class, get_parent_uri);
- LILV_WRAP0(Value, plugin_class, get_uri);
- LILV_WRAP0(Value, plugin_class, get_label);
+ LILV_WRAP0(Node, plugin_class, get_parent_uri);
+ LILV_WRAP0(Node, plugin_class, get_uri);
+ LILV_WRAP0(Node, plugin_class, get_label);
inline LilvPluginClasses* get_children() {
return lilv_plugin_class_get_children(me);
@@ -116,7 +116,7 @@ struct PluginClass {
LILV_WRAP_COLL(PluginClasses, PluginClass, plugin_classes);
LILV_WRAP_COLL(ScalePoints, ScalePoint, scale_points);
-LILV_WRAP_COLL(Values, Value, values);
+LILV_WRAP_COLL(Nodes, Node, nodes);
struct Plugins {
inline Plugins(const LilvPlugins* c_obj) : me(c_obj) {}
@@ -129,26 +129,26 @@ struct World {
inline World() : me(lilv_world_new()) {}
inline ~World() { /*lilv_world_free(me);*/ }
- inline LilvValue* new_uri(const char* uri) {
+ inline LilvNode* new_uri(const char* uri) {
return lilv_new_uri(me, uri);
}
- inline LilvValue* new_string(const char* str) {
+ inline LilvNode* new_string(const char* str) {
return lilv_new_string(me, str);
}
- inline LilvValue* new_int(int val) {
+ inline LilvNode* new_int(int val) {
return lilv_new_int(me, val);
}
- inline LilvValue* new_float(float val) {
+ inline LilvNode* new_float(float val) {
return lilv_new_float(me, val);
}
- inline LilvValue* new_bool(bool val) {
+ inline LilvNode* new_bool(bool val) {
return lilv_new_bool(me, val);
}
- LILV_WRAP2_VOID(world, set_option, const char*, uri, LilvValue*, value);
+ LILV_WRAP2_VOID(world, set_option, const char*, uri, LilvNode*, value);
LILV_WRAP0_VOID(world, free);
LILV_WRAP0_VOID(world, load_all);
- LILV_WRAP1_VOID(world, load_bundle, LilvValue*, bundle_uri);
+ LILV_WRAP1_VOID(world, load_bundle, LilvNode*, bundle_uri);
LILV_WRAP0(const LilvPluginClass*, world, get_plugin_class);
LILV_WRAP0(const LilvPluginClasses*, world, get_plugin_classes);
LILV_WRAP0(Plugins, world, get_all_plugins);
@@ -167,14 +167,14 @@ struct Port {
#define LILV_PORT_WRAP1(RT, name, T1, a1) \
inline RT name (T1 a1) { return lilv_port_ ## name (parent, me, a1); }
- LILV_PORT_WRAP1(LilvValues*, get_value, LilvValue*, predicate);
- LILV_PORT_WRAP0(LilvValues*, get_properties)
- LILV_PORT_WRAP1(bool, has_property, LilvValue*, property_uri);
- LILV_PORT_WRAP1(bool, supports_event, LilvValue*, event_uri);
- LILV_PORT_WRAP0(const LilvValue*, get_symbol);
- LILV_PORT_WRAP0(LilvValue*, get_name);
- LILV_PORT_WRAP0(const LilvValues*, get_classes);
- LILV_PORT_WRAP1(bool, is_a, LilvValue*, port_class);
+ LILV_PORT_WRAP1(LilvNodes*, get_value, LilvNode*, predicate);
+ LILV_PORT_WRAP0(LilvNodes*, get_properties)
+ LILV_PORT_WRAP1(bool, has_property, LilvNode*, property_uri);
+ LILV_PORT_WRAP1(bool, supports_event, LilvNode*, event_uri);
+ LILV_PORT_WRAP0(const LilvNode*, get_symbol);
+ LILV_PORT_WRAP0(LilvNode*, get_name);
+ LILV_PORT_WRAP0(const LilvNodes*, get_classes);
+ LILV_PORT_WRAP1(bool, is_a, LilvNode*, port_class);
LILV_PORT_WRAP0(LilvScalePoints*, get_scale_points);
// TODO: get_range (output parameters)
@@ -188,31 +188,31 @@ struct Plugin {
LILV_WRAP_CONVERSION(const LilvPlugin);
LILV_WRAP0(bool, plugin, verify);
- LILV_WRAP0(Value, plugin, get_uri);
- LILV_WRAP0(Value, plugin, get_bundle_uri);
- LILV_WRAP0(Values, plugin, get_data_uris);
- LILV_WRAP0(Value, plugin, get_library_uri);
- LILV_WRAP0(Value, plugin, get_name);
+ LILV_WRAP0(Node, plugin, get_uri);
+ LILV_WRAP0(Node, plugin, get_bundle_uri);
+ LILV_WRAP0(Nodes, plugin, get_data_uris);
+ LILV_WRAP0(Node, plugin, get_library_uri);
+ LILV_WRAP0(Node, plugin, get_name);
LILV_WRAP0(PluginClass, plugin, get_class);
- LILV_WRAP1(Values, plugin, get_value, Value, pred);
- LILV_WRAP2(Values, plugin, get_value_for_subject, Value, subject,
- Value, predicate);
- LILV_WRAP1(bool, plugin, has_feature, Value, feature_uri);
- LILV_WRAP0(Values, plugin, get_supported_features);
- LILV_WRAP0(Values, plugin, get_required_features);
- LILV_WRAP0(Values, plugin, get_optional_features);
+ 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);
+ LILV_WRAP0(Nodes, plugin, get_optional_features);
LILV_WRAP0(unsigned, plugin, get_num_ports);
LILV_WRAP0(bool, plugin, has_latency);
LILV_WRAP0(unsigned, plugin, get_latency_port_index);
- LILV_WRAP0(Value, plugin, get_author_name);
- LILV_WRAP0(Value, plugin, get_author_email);
- LILV_WRAP0(Value, plugin, get_author_homepage);
+ LILV_WRAP0(Node, plugin, get_author_name);
+ LILV_WRAP0(Node, plugin, get_author_email);
+ LILV_WRAP0(Node, plugin, get_author_homepage);
inline Port get_port_by_index(unsigned index) {
return Port(me, lilv_plugin_get_port_by_index(me, index));
}
- inline Port get_port_by_symbol(LilvValue* symbol) {
+ inline Port get_port_by_symbol(LilvNode* symbol) {
return Port(me, lilv_plugin_get_port_by_symbol(me, symbol));
}
@@ -223,8 +223,8 @@ struct Plugin {
me, min_values, max_values, def_values);
}
- inline unsigned get_num_ports_of_class(LilvValue* class_1,
- LilvValue* class_2) {
+ inline unsigned get_num_ports_of_class(LilvNode* class_1,
+ LilvNode* class_2) {
// TODO: varargs
return lilv_plugin_get_num_ports_of_class(me, class_1, class_2, NULL);
}