From 5ea69340e389163cfea54c16a466672b9b7284b8 Mon Sep 17 00:00:00 2001 From: David Robillard Date: Sat, 20 Feb 2021 13:17:03 -0500 Subject: Rename SerdURI to SerdURIView --- src/writer.c | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) (limited to 'src/writer.c') diff --git a/src/writer.c b/src/writer.c index e97af301..c365f23c 100644 --- a/src/writer.c +++ b/src/writer.c @@ -96,8 +96,8 @@ struct SerdWriterImpl { SerdStyle style; SerdEnv* env; SerdNode root_node; - SerdURI root_uri; - SerdURI base_uri; + SerdURIView root_uri; + SerdURIView base_uri; SerdStack anon_stack; SerdByteSink byte_sink; SerdErrorSink error_sink; @@ -151,7 +151,7 @@ w_err(SerdWriter* writer, SerdStatus st, const char* fmt, ...) } static inline SERD_PURE_FUNC WriteContext* -anon_stack_top(SerdWriter* writer) + anon_stack_top(SerdWriter* writer) { assert(!serd_stack_is_empty(&writer->anon_stack)); return (WriteContext*)(writer->anon_stack.buf + writer->anon_stack.size - @@ -600,14 +600,14 @@ write_uri_node(SerdWriter* const writer, write_sep(writer, SEP_URI_BEGIN); if (writer->style & SERD_STYLE_RESOLVED) { - SerdURI in_base_uri; - SerdURI uri; - SerdURI abs_uri; + SerdURIView in_base_uri; + SerdURIView uri; + SerdURIView abs_uri; serd_env_get_base_uri(writer->env, &in_base_uri); serd_uri_parse(node->buf, &uri); serd_uri_resolve(&uri, &in_base_uri, &abs_uri); - bool rooted = uri_is_under(&writer->base_uri, &writer->root_uri); - SerdURI* root = rooted ? &writer->root_uri : &writer->base_uri; + bool rooted = uri_is_under(&writer->base_uri, &writer->root_uri); + SerdURIView* root = rooted ? &writer->root_uri : &writer->base_uri; if (!uri_is_under(&abs_uri, root) || writer->syntax == SERD_NTRIPLES || writer->syntax == SERD_NQUADS) { serd_uri_serialise(&abs_uri, uri_sink, writer); @@ -952,12 +952,12 @@ serd_writer_finish(SerdWriter* writer) } SerdWriter* -serd_writer_new(SerdSyntax syntax, - SerdStyle style, - SerdEnv* env, - const SerdURI* base_uri, - SerdSink ssink, - void* stream) +serd_writer_new(SerdSyntax syntax, + SerdStyle style, + SerdEnv* env, + const SerdURIView* base_uri, + SerdSink ssink, + void* stream) { const WriteContext context = WRITE_CONTEXT_NULL; SerdWriter* writer = (SerdWriter*)calloc(1, sizeof(SerdWriter)); -- cgit v1.2.1