aboutsummaryrefslogtreecommitdiffstats
path: root/src/serdi.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/serdi.c')
-rw-r--r--src/serdi.c22
1 files changed, 11 insertions, 11 deletions
diff --git a/src/serdi.c b/src/serdi.c
index 1ebd5e85..cda8aa21 100644
--- a/src/serdi.c
+++ b/src/serdi.c
@@ -147,34 +147,34 @@ serd_fopen(const char* const path, const char* const mode)
return fd;
}
-static SerdStyle
+static SerdWriterFlags
choose_style(const SerdSyntax input_syntax,
const SerdSyntax output_syntax,
const bool ascii,
const bool bulk_write,
const bool full_uris)
{
- unsigned output_style = 0u;
+ SerdWriterFlags writer_flags = 0u;
if (output_syntax == SERD_NTRIPLES || ascii) {
- output_style |= SERD_STYLE_ASCII;
+ writer_flags |= SERD_WRITE_ASCII;
} else if (output_syntax == SERD_TURTLE) {
- output_style |= SERD_STYLE_ABBREVIATED;
+ writer_flags |= SERD_WRITE_ABBREVIATED;
if (!full_uris) {
- output_style |= SERD_STYLE_CURIED;
+ writer_flags |= SERD_WRITE_CURIED;
}
}
if ((input_syntax == SERD_TURTLE || input_syntax == SERD_TRIG) ||
- (output_style & SERD_STYLE_CURIED)) {
+ (writer_flags & SERD_WRITE_CURIED)) {
// Base URI may change and/or we're abbreviating URIs, so must resolve
- output_style |= SERD_STYLE_RESOLVED;
+ writer_flags |= SERD_WRITE_RESOLVED;
}
if (bulk_write) {
- output_style |= SERD_STYLE_BULK;
+ writer_flags |= SERD_WRITE_BULK;
}
- return (SerdStyle)output_style;
+ return writer_flags;
}
int
@@ -312,7 +312,7 @@ main(int argc, char** argv)
: SERD_NQUADS);
}
- const SerdStyle output_style =
+ const SerdWriterFlags writer_flags =
choose_style(input_syntax, output_syntax, ascii, bulk_write, full_uris);
SerdURIView base_uri = SERD_URI_NULL;
@@ -327,7 +327,7 @@ main(int argc, char** argv)
SerdEnv* const env = serd_env_new(&base);
SerdWriter* const writer = serd_writer_new(
- output_syntax, output_style, env, &base_uri, serd_file_sink, out_fd);
+ output_syntax, writer_flags, env, &base_uri, serd_file_sink, out_fd);
SerdReader* const reader =
serd_reader_new(input_syntax,