From 23ef7a21c277ba5e864748d8e61ff3e20054758f Mon Sep 17 00:00:00 2001 From: David Robillard Date: Sun, 30 Jan 2011 21:27:39 +0000 Subject: Add blank node type for value, to allow the user to 'join' statement queries on blank node values with the simple get_value functions. Remove use of SPARQL from lv2_inspect. git-svn-id: http://svn.drobilla.net/lad/trunk/slv2@2874 a436a847-0d15-0410-975c-d299462d15a1 --- slv2/value.h | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) (limited to 'slv2') diff --git a/slv2/value.h b/slv2/value.h index fcb3143..86be450 100644 --- a/slv2/value.h +++ b/slv2/value.h @@ -124,6 +124,27 @@ const char* slv2_value_as_uri(SLV2Value value); +/** Return whether the value is a blank node (resource with no URI). + * + * Time = O(1) + */ +SLV2_API +bool +slv2_value_is_blank(SLV2Value value); + + +/** Return this value as a blank node identifier, e.g. "genid03". + * + * Valid to call only if slv2_value_is_blank(\a value) returns true. + * Returned value is owned by \a value and must not be freed by caller. + * + * Time = O(1) + */ +SLV2_API +const char* +slv2_value_as_blank(SLV2Value value); + + /** Return whether this value is a literal (i.e. not a URI). * * Returns true if \a value is a string or numeric value. -- cgit v1.2.1