Age | Commit message (Collapse) | Author | Files | Lines |
|
The old interface was potentially faster, because it avoided unnecessary
copies, but was annoying to use and problematic because nodes that don't need
expansion were indistinguishable from nodes that failed to expand (like those
that use undefined namespace prefixes).
In the grand scheme of things, the potential performance improvement isn't
worth it, and unexpected unexpanded nodes causes deep nightmarish problems, so
just make serd_env_expand() copy the input if it doesn't need expansion to make
the API simpler and safer.
|
|
|
|
This is convenient in places where you don't necessarily need an Env, since in
this case these methods work the same as if with an empty Env.
|
|
This makes plumbing easier since everything goes through the same "stream" and
only one callback is required to handling everything. It's also more easily
extensible in case more event types need to be added in the future.
|
|
This can be used to associate dynamically allocated data with a sink and have
it managed along with the sink's lifetime.
|
|
|
|
This is not particularly useful except to write prefixes, which is what
serd_env_write_prefixes is for, and the name implies that namespace prefixes
are the only thing in an Env, which will be problematic in the future.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
The constant casting just makes user code a mess, for no benefit.
|
|
|