RedlandDave Beckett |
|||||
|
Hosted by
since 2005. RaptorDemonstrationsData |
Raptor RDF Syntax Library - Release NotesRaptor2 2.0.16 changesRelease because ... it's been a while CVE-2017-18926 fixed in commit 590681e546cd9aa18d57dc2ea1858cb734a3863f CVE-2020-25713 fixed in commit 4f5dbbffcc1c6cf0398bd03450453289a0979dea Issues Fixed:
Parser changesThe Turtle parser was improved to process input in chunks, rather
than all in one step (with a large memory buffer). This allows
Turtle to read and parse files much larger than the system memory; it
splits the inputs after the end of a turtle "sentence" that ends in a
Turtle parser improvements for Bison 3+ and removing deprecated or older style directives. Thanks to fix from Akim Demaille Pull Request #43 Turtle parser fixes for cleaning up va_arg on failure paths. [coverity CID 343351] grddl parser: fix leak on failure paths of WWW model methods [coverity CID 343353] Serializer changesAdded a serializer for the
mKR (my Knowledge Representation)
language with the name XML writer calculate max nspace declarations correctly. Fixes Issues #0000617 and #0000618 JSON writer changed to write UTF-8 for JSON literals
Add rdfxmla serializer was fixed to handle leak of iter object on some failure pathes. [coverity CID 343354] [coverity CID 343358] Fix for RSS 1.0 serializing default namespaces. Writer changesXML Writer: compare namespace declarations correctly. Applied a patch from 0001-CVE-2020-25713-raptor2-malformed-input-file-can-lead.patch.1 that fixes Issue #0000650 which overwrote heap during XML writing in parse type literal content. This was detected with clang asan. Thanks to fix from Michael Stahl / mst2. Build and portability fixesCMake fixes
Remove and fix obsolete autoconf: AC_PROG_LEX AC_HEADER_TIME AC_HEADER_STDC. Update bison check to find first new enough GNU bison Fix configure.ac Support newer ICU UC version (>=56) for newer NFC check
interface Several minor fixes and workarounds for clang ASAN warnings or false warnings - not able to understand raptor's reference model. Updated fix-flex.pl script for newer flex naming conventions. Portability fixes found with GCC 10 and newer compilers for wrong error message callbacks in turtle and grddl parsers Later, updated to make bison 3.4 the minimum. Update turtle parser and support scripts to work with Bison 3.0.5 Patch contributed by Adam Novak. Thanks. Pull Request #39 Fix GNUInstallDirs for install paths to be able to install libraptor2.a and raptor2.pc to a specific directory when cross-compiling. Thanks to fix from Eric Le Lay. Pull Request #36 Made some code changes to quiet GCC extra warnings. Portability fixes for OpenBSD Some portability for building under cygwin by Richard H. McCullough while developing the mkr serializer. Portability fixes in the Enable Use only pkgconfig for libxslt and ICU UC. Patches from Hugh McMaster. Thanks. Updated Travis configuration to try builds across a wider range of compilers and with clang ASAN enabled. Other changesHandle deleting empty avltree. Fixes invalid pointer reference reported by Li Qiang via email. Thanks. Change Accept cygwin as a Linux-like. Fixes Issue #0000600. Mention Atom 0.3 in docs and manual page Fixes Issue #0000652. Check Fixed internal ICU string NFC check to convert to UTF-16 first before trying to do a NFC normalization check. This allows returning an error response.
Raptor2 2.0.15 changesThis release mainly made general bug fixes as well as several
fixes to the Turtle / N-Triples family of parsers and serializers. It
added utility functions for re-entrant sorting of objects and
sequences and a few other useful methods. Issues Fixed:
Parser changesFixed The TRiG parser now accepts \r newlines between the graph name and the following '{'. Fixes Issue #0000584 Turtle, TRiG, N-Triples and N-Quads parsers now check escapes correctly for URI strings. \t \b \n \r \f are forbidden. Check that raw ' ' or \u0020, \u003C or \u003E are also not accepted. Fixes Issue #0000577 N-Triples / N-Quads parsers nwo accept '_' as an alias for '-' in lang strings. '_' is not legal. Fixes Issue #0000574 Updated RDFa parser (librdfa) to support full URLs for
Serializer changesTurtle serializer now writes I/O-stream class changes
Term class changes
URI class changesFixed
Fixed Writer class changesFixed World class changesAdded Other ChangesMade raptor work with Travis CI again; have to download and install Bison 3. Added Ensure Fix a -99 <= var <= 99 timezone interval check. Thanks to Richard Trieu for the report. Improve configure warning check using AC_LANG_WERROR Use C99 Improve build-time flex and bison output to be more silent. Added Intel C compiler (icc) support from Sebastian Freundt (hroptatyr on GitHub) - Thanks. Raptor2 2.0.14 changesMany code quality fixes from clang and coverity primarily in error path cleanups (out of memory cases) and dead code. Parser changesTurtle 1.1 parser: fixes about triple quoting alignment with SPARQL from the www-rdf-comments list post REC report of problem and expected answer. Other changesFixed RDFa 1.0 and RDFa 1.1 test suites to properly report failures. Updated the fix-flex and fix-bison scripts to remove dead code that clang and coverity complain about. Raptor2 2.0.13 changesIssues Fixed:
Parser changesThe N-Triples / N-Quads parser was updated to allow ' in URIs. Fixes Issue #0000562. Configuration changesUse the discovery of the Updated to use the Internal changesThe Turtle and parsedate parsers and the turtle lexer were updated to use and require Bison 3.0.0. The JSON and turtle writers were updated to save several expensive
Raptor2 2.0.12 changesParser changesThe N-Triples / N-Quads parser was updated to pass all the two test suites for the updated specifications:
The main fixes were:
Term class changesAdded Raptor2 2.0.11 changesIssues Fixed:
Parser changesN-Triples parser was updated to support all of
RDF 1.1
N-Triples - A line-based syntax for an RDF graph (aka N-Triples 2013)
It now supports RDF/XML parser fixed the XML Canonicalization so that it writes the XML attributes in sorted order. Fixes Issue #0000554. URI class changesAdded QName class changesAdded Configuration and build changesRestructured code to build an internal librdfa convenience library (never installed) so that newer automake will stop moaning about subdir-objects.
Various portability and build fixes (Daniel Richard G) Build fixes: Other changesFixed a few issues found with LLVM 3.4 (SVN) run with address sanitizing. Raptor2 2.0.10 changesIssues Fixed:
Parser changesTurtle parser was updated to handle Turtle Terse RDF Triple Language W3C Candidate Recommendation 19 February 2013 (Turtle 2013) The main changes were to align with SPARQL-style blank node names, prefixes and local names. N-Triples parser was updated to handle N-Triples - A line-based syntax for an RDF graph W3C Working Group Note 09 April 2013 (N-Triples 2013) The main changes were to allow \b \f, UTF-8 in strings and URIs and the SPARQL-style blank node names. RDF/XML parser updated to understand the new RDF 1.1 datatypes: rdf:HTML and rdf:langString Serializer changesUpdated N-Triples and Turtle serializers (via writers) for 2013 versions based on SPARQL 1.1 definitions. These new formats have incompatible changes. Added functions for writing escaped Turtle / N-Triples terms: int raptor_string_escaped_write(const unsigned char *string, size_t len, const char delim, unsigned int flags, raptor_iostream *iostr); int raptor_term_escaped_write(const raptor_term *term, unsigned int flags, raptor_iostream* iostr); int raptor_uri_escaped_write(raptor_uri* uri, raptor_uri* base_uri, unsigned int flags, raptor_iostream *iostr); These uses the new new Deprecated Configuration and build changes
Updated autogen.sh and code to handle variations of header macro. Fixes Issue #0000532 Raptor2 2.0.9 changesIssues Fixed:
Parser ChangesRDFa parser: Handle non-namespaced elements without crash in RDFa. Fixes Issue #0000521 Turtle Parser: Added full support for Turtle Terse RDF Triple Language W3C Candidate Recommendation 19 February 2013 This includes accepting new keywords from SPARQL
( Serializer changesTurtle Serializer: Added full support for Turtle Terse RDF Triple Language W3C Candidate Recommendation 19 February 2013 which particular effects the encoding of URIs in the serializer. Configuration and build changesAdded CMake build framework for building Raptor on Microsoft
Windows. Removed the old Ensure that a small system BUFSIZ does not affect parser guessing Patch from Daniel Richard G for Teragram Inc. Added a compile-time check for
Update
Handle the libxml2 Other changes
Remove Raptor2 2.0.8 changesIssues Fixed:
Parser class changesGuessing a parser with
Guess parser: now returns error file and line location information from the guessed parser. RDFa parser: Updated librdfa to the latest GIT supporting RDFa 1.1 with 30 tests still not passing - mostly issues in the core librdfa. Made several resilience and crash fixes. Updated the RDFa 1.0 test suite to latest tests and made fixes. The RDFa parser now accepts aliases 'rdfa10', 'rdfa11' and the default 'rdfa' is RDFa 1.1 RSS tag soup parser: Use RDF/XML parser: The range of RDF/XML entity recognizing heuristic was broadened to allow recognition of documents produced by Stanford's Protege software (and possibly others). Fixed some parser memory leaks / double frees. Turtle parser: Do not report multiple errors for Turtle string decoding problems. When a Turtle qname cannot be found, a fatal error is no longer generated but a regular error message giving information on the qname that failed (usually due to unknown prefix). Fixes Issue #0000507 SAX2 API changes
Serializer class changesTurtle: Do not emit a Turtle Term class changesAdded Unicode class changes
URI class changesFixed URI resolving with reference (relative) URIs that are bare queries like '?y' with no path. Now matches the specification RFC3986 section 5.4.1 Normal Examples. Added Added WWW class changesThe Curl WWW implementation now interprets
Configuration and build changesAll configure --with-foo options now handle --without-foo (and --with-foo=no) to disable attempting to find the value in the PATH. This can be used with --with-xml2-config, --with-xslt-config, --with-curl-config, --with-icu-config and --with-libwww-config where the value 'no' or --without-foo can be used to disable it and prevent automatic searches for the config script in the PATH. The The The existing
The Other changesMultiple portability improvements to vsnprintf code and macros. Also fixed uninitialized variable problems in non-c99 variant of raptor_vsnprintf2(). Thanks to John Emmas for reporting. Multiple portability fixes for building out of the source tree. Out of source tree 'make check' and 'make dist' should both work. Thanks to Daniel Richard G. for the patches. Multiple portability fixes for building on old Solaris versions. Thanks to Daniel Richard G. for the patches. Multiple portability fixes for building on Windows including strcasecmp(), windows headers, configuration fixes, parsedate code, URI test builds, vsnprintf building. Thanks to Daniel Richard G. for the patches. Updated the example Raptor2 2.0.7 changesCVE-2012-0037 fixed Issues Fixed:
Removed Expat support since expat has not had a release in years
and libxml2 works well. This allows some code simplification.
Updated Removed internal Unicode NFC checking code used for checking RDF/XML literals conformance which was expensive to check and a large of compiled-in static dataset that was rather out of date. Replaced with optional compiled use of ICU. If ICU is not explicitly configured, no literal checking is done. Options changesAdded new options:
Parser class changesThe RDF/XML, RSS Tag Soup and RDFa parsers now pass on network, file and entity loading parser options to the internal SAX2 to enable enforcing of network, file and entity loading policy. RDF/JSON parser handles an API change between YAJL V1 and V2. Turtle parser now returns parser errors to
SAX2 class changesAdded Control file and network loading inside SAX2. Option
URI class changesAdded new URI constructor
Added
Added utility methods for checking if a file: URI or filename is a
file that exists:
WWW class changesAdded The Build changesAdded Requires automake 1.11.2+ for
Raptor2 2.0.6 changesFixed expat support which was broken in 2.0.5 Handle libCurl SSL options before 7.16.4 (that's 2007) since old libcurl is still around on Enterprise (that means old) linux systems. Sequence ChangesAdded utility functions to swap elements, reverse the sequence and generate permuations: int raptor_sequence_swap(raptor_sequence* seq, int i, int j); int raptor_sequence_reverse(raptor_sequence* seq, int start_index, int length); int raptor_sequence_next_permutation(raptor_sequence *seq, raptor_data_compare_handler compare); Raptor2 2.0.5 changesIssues Fixed:
Parser class changesUpdated all parser URIs to use the W3C Format URIs as the primary URIs. Existing URIs become aliases. (Nicholas J Humfrey) GRDDL parser: Correctly set the base_uri when resolving the sheet URI. N-Quads parser: Make context optional. (Lauri Aalto)
Fixes
Issue #0000479.
RDFA parser: fix when building with 64-bit systems to prevent value truncation. Turtle parser: now uses the official text/turtle mime type in the syntax recognizing code. Serializer class changesUpdated all serializer URIs to use the W3C Format URIs as the primary URIs. Existing URIs become aliases. (Nicholas J Humfrey) Turtle serializer now uses the official text/turtle mime type in the syntax recognizing code. Do not generate infinite output when the input Unicode UTF-8 encoding is bad. Fixes Issue #000481. Unicode class changesAdded new utility functions for calculating number of Unicode
characters in a UTF-8
string int raptor_unicode_utf8_strlen(const unsigned char *string, size_t length); size_t raptor_unicode_utf8_substr( unsigned char* dest, size_t* dest_length_p, const unsigned char* src, size_t src_length, int startingLoc, int length); URI class changes
Build changesThe library no longer needs
Other changesRecords GIT version in the version string when building from GIT
sources with Added internal Added int raptor_vsnprintf2(char *buffer, size_t size, const char *format, va_list arguments); int raptor_snprintf(char *buffer, size_t size, const char *format, ...); int raptor_vasprintf(char **ret, const char *format, va_list arguments);
Internal code style changes for how allocation is done and casting with new macros.
Updated code to use Raptor2 2.0.4 changesIssues Fixed:
Parser class changesThe
RDF/JSON parser: Gains support for building with YAJL V2. Note that YAJL V1 and V2 both install the same library name 'libyajl' even though they have different ABI and APIs. TRiG parser: Fixed to support the legal uri Turtle parser: Modified to not include the internal
Serializer class changesN-Triples and Turtle serializers: Now
use WWW class changesAdded support for Added Other changesMake Raptor build against Curl 7.21.7 which removed a header file that was made an empty file in the libcurl source code on April 26 2004 around version 7.12.0 which is now the minimum version Raptor supports.. Fixed an AVL Tree issue during deletion that messes up some pointers. Patch from 'v-for-vandal'. Thanks. Added a utility function
Expanded GCC warnings and corrected a few internal uses
of Reduced stack use of Raptor2 2.0.3 changesThe main change is to add the new main header file
Turtle / TRiG parser changesAlter the parser to not use a large token stack when parsing TRiG graphs, enabling the parser to handle much larger files. The parser still gathers all input into a single memory segment so the maximum amount of input is probably memory size/3. TRiG parser now allows a QName for the graph name. Attempted to make the parser handle streaming lexing and parsing but only partially successful; bison could be made to stream parse but flex could not be made to stream lex. This meant it could not be convinced to return a "need more input" response at the end of a chunk of data and continue lexing later. Fix value ownership fix graph name. Fixes Issue #0000437 Other ChangesRaptor was ran through the LLVM clang static code analyzer and several issues fixed, mostly in unused variables and in unlikely error recovery conditions. Some actual potential crash bugs were found:
Bison 2.4 is required to build Raptor from GIT source with no pregenerated files. Raptor2 2.0.2 changesFixed a too strict version checking bug in Raptor 2.0.1 ChangesDO NOT USE. Use 2.0.2 which fixes a too strict version
checking bug in Parser class changesThe internal librdfa parser that uses Raptor internals now exports symbols prefixed with raptor_librdfa so that Raptor can be linked with the standard librdfa in applications without symbol clashes. Fixes Issue #0000416 Serializer class changesThe N-Quads serializer was fixed to output the graph name in the fourth column, instead of repeating the object. Internal changesReplaced all internal fatal errors that went to
an Raptor 2.0.0 ChangesRaptor V2 final release. See the release notes for 1.9.0 and 1.9.1 for the major changes in Raptor V2. API changes since 1.9.1 betaAdded The Fixed guessing by URI in
Fixed Issues:
Raptor 1.9.1 Changes1.9.1 is the second beta release of Raptor 2 and intended to be the last release before 2.0.0. Raptor V1 to V2 upgrading changesImproved the Added defensive code in each constructor to check the passed-in raptor world object is a valid Raptor V2 world rather than V1. It generates a warning once per run of the program. The AVLTree class changesFree the iterator at the end of debug method
I/O Stream class changesFix major copying too much error in the internal
Parser class changesJSON parser: Made relative URIs option work. N-Quads parser: Added. The serializer already existed. librdfa parser: Updated to latest librdfa GIT 1a1a08c790b7649a7f6c12fb9e40c0d3dbe70481 Serializer class changesFix RSS/Atom serializer: Fix crashes with feeds containing entries with blank node items. Stringbuffer class changesAdded utility methods
Term class changesDeleted Added Added URI class changesAdded convenience methods for constructing URI terms from strings:
Use string lengths in equals and comparisons for faster checking.
Use WWW class changesThe CURL WWW module now looks for and uses the HTTP response
Raptor 1.9.0 Changes1.9.0 is the first beta release of Raptor 2. There may be changes and additional releases before version 2.0.0 with the final stable API. This is a major update and cleanup to the Raptor API and ABI with additions, removals and changes. There are also major restructurings of the internal code and cleanups. There are also some new features in the form of additional APIs, new serializers and parsers. The details of the additions, removals and changes of functions, structures, typedefs and enums are listed in the Raptor 2 API reference manual section on Changes between raptor 1.4.21 and 1.9.0. The upgrading document explains how to upgrade existing code that uses the V1 APIs to use the new APIs. The major changes in this release are:
Fixed Issues:
General changesRenamed the library name and package tarball name to a new
separate names (libraptor2, raptor2-X.tar.gz) so they can be
distinguished and installed into the same system as raptor 1 without
file clashes. Note: This does not apply to the
Nicholas J Humfrey is a new committer. A utility script Raptor's Statement, Term and URI classes can fully replace
librdf's Documentation changesThe API reference manual now includes an automatically generated reference section on the functions and types that were added, removed and changed between raptor 1 and raptor 2 APIs. It also includes an automatically generated section on the parser and serializers with their names, mime types and Q values. The tutorial examples were updated to the Raptor 2 APIs. NOTE: At this time, the descriptive parts of the tutorial have NOT been updated to use the Raptor 2 API. World class changesA log handler function for receiving warnings and errors (fatal or
other) are now all sent to a single log handler of type
The enumerating approach for listing the known parsers and
serializers and writing into variables passed in, was replaced with
methods that return pointers to static
Moved the generation of blank node IDs from the parsers (many
objects) to the world class (1 object). Cannot think of good reasons
why the blank node ID generation policy needs to be different
per-parser. Enumeration AVL Tree changesThe internal memory-based AVL Tree implementation is exposed as a public API. Features changesReplaced with Identifier class changesReplaced with Term class.
I/O Stream class changesConstructors all gain a world argument. Some methods now return an int error status such as
Many classes iostream writing methods and methods of the iostream
class itself were changed to follow the standard
Deprecated typedef Deprecated functions were removed:
Locator changesRenamed some methods to follow the
Namespaces and namespace stack classes changesConstructors all gain a world argument and lose error handler, error data arguments. OptionsA new name for what were called features in Raptor 1 and this was
expanded to allow use of values types string, integer and boolean.
Options can be set on multiple classes such as parser, serializer but
are centrally described using the new
The option get / set operations were reduced from multiple methods per class for getting / setting an int, int / string to just one get and one set, with optional parameters. It can also handle adding new types later, which will be passed in as strings and converted internally. The options code
introduces a new enum Parser class changes
Parser object methods to return information about the parser class
were removed since they can be done instead via fields of the static
object returned from
Parsing may generate start graph and end graph events for syntaxes
that return graph names such as TRiG. These are returned by the handler
of typedef
Many functions were renamed to match the
Deprecated typedef Deprecated functions were removed:
The librdfa parser was updated with the latest updates to the RDFa syntax (first, rel/rev, whitespace, xml:lang) and fixes issues with non-terminated strings. The GRDDL parser now saves and restores the libxslt global state
(handlers, security preferences) so that it does not affect other
applications in the same memory space. Part of this can be
overridden with
The RDF/XML parser never generated special names for bag IDs (bagidNNN), so all support for that has been removed. The RDF/XML parser uses the new reference-counted URIs and raptor terms to prevent a lot of malloc/free for temporary uses. Removed RDF/XML parser feature
Added a JSON parser (name 'json') that can read both the resource-centric and triples JSON RDF formats. Requires the YAJL JSON parser library. Contributed by Nicholas J Humfrey. Moved the generation of blank node IDs from the parsers (many objects) to the world class (1 object). Cannot think of good reasons why the blank node ID generation policy needs to be different per-parser. QName class changesConstructors all gain a world argument and lose error handler, error data arguments. Sequence changesUse new generic Serializer class changesAdded Added an HTML Table serializer with name 'table' contributed by Nicholas J Humfrey. Removed the obsolete 'simple' serializer from the source code. N-Triples is an appropriate simple (and well-defined) replacement syntax. Statement class changesThis was made a more regular class that can be created, copied and freed using reference counting. The structure changed to be an array of 4 raptor terms rather than a complex union focused on the allowed RDF Statements. This change allows representing non-RDF triples as well as triples with named graphs (also known as quads).
Term class changesThis new class with an open structure replaces
This class can fully replace librdf's librdf_node when both Rasqal
and librdf are built with Unicode changesSeveral utility functions were renamed to match their
functionality more accurately and be associated with the Unicode
module set of functions. For example URI class changesThe whole concept of URI handlers was removed, there is no longer a way to replace the implementation of the URI class. The implementation built in now interns URIs string so that a single URIs for a string is only ever in memory once, but reference counted. This is what Redland librdf has done for many years, and librdf can fully use this. Deprecated functions were removed:
The WWW class changesRename several of the functions to the standard constructor, destructor and method naming format. XML Writer class changesConstructors all gain a world argument and lose error handler, error data arguments. Configuration changesAdded configure argument Raptor headers are now installed in a sub-directory of
PREFIX
cc -o prog prog.c `pkg-config raptor2 --cflags` `pkg-config raptor2 --libs` Internal changesCode style: lots of changes mostly adding lots more whitespace such as to show control change (if, while) or early function exit (return). All Code style:
use Code style: put whitespace round assignment and operators i.e.
use Code style: removed some Code style: try to remove un-necessary Code style: methods called with a NULL object return failure
and destructors called with a NULL object return silently rather than
the former mix of crashing or Code style: copy constructor is now called
Code style: print methods return an int return status indicating success. rapper Utility changesPrint out the option types next to the description in the Removed unused Did NOT rename Removed long deprecated Removed Other changesRemoved support for building raptor with dmalloc debugging
(removing The example 'grapper' GNOME GUI utility for raptor was updated to the latest GTK APIs (2.5.0+ but still quite old) so that it builds with all the GTK 'disable deprecated' flags set. The UI is not quite correct though - the preferences menu is broken. Switched to GIT version control, hosted by GitHub. The latest raptor 1 code is available on branch 'raptor1' as well as from the release tags for specific versions. Raptor 1.4.21 ChangesThis is a bug fix only release with no new features. New development has moved to raptor 2 where a planned ABI and API break is underway. Fixed Issues:
Parser changesN-Triples parser: Declare acceptance of text/plain mime type with q=0.1 RDFA parser (via librdfa): Updated to fix some buffer management problems when it was passed large blocks (4096 bytes or more), a few memory leaks and some other minor bugs. RDF/XML parser: Properly reset the ID-checking set at the start of each parse. Turtle parser: Allow \\ at the end of triple-quoted literals. Forbid '.'s in prefixes and qnames (follow specification). Properly count newlines inside the literals for error reporting. Serializer changesTurtle serializer: Forbid '.'s in prefixes and qnames (follow specification). Other ChangesUpdated
Raptor 1.4.20 ChangesThis is a bug fix only release with no new features. New development has moved to raptor 2 where a planned ABI and API break will happen. There may be preview releases of raptor 2 with 1.9.x numbering. Fixed Issues:
Parser Changes
GRDDL parser: Fix XML parser context resource leak if
RDFA parser (via librdfa): Update to latest librdfa GIT sources with head
a438ce68a40e04b399ec2b2c613d0c867d9315c7 Added three unapproved RDFa tests 0172, 0173 and 0174 to cover the fixes above. Serializer Changes
Turtle serializer:
Applied scalability patch from Chris Cannam.
This switches the serializer to use a Other ChangesIf cross compiling, check for Use Use
Raptor 1.4.19 Changes
Fixed Issues:
Parser Changes
Guess parser: return name of guessed parser not 'guess'. N-Triples parser:
Produce error messages when raptor_new_uri() fails. RDFa parser:
Fix problem when there is a subject and predicate specified on an
element, but no child nodes for the object literal using
latest librdfa GIT source with head
2ddcb3f9e010d0b3d9ee546e807539be5da1b14a RSS tag soup parser:
Huge internal changes: RDF/XML Parser:
Adjust predicate_type when removing ordinal identifier type from predicate. Serializer ChangesAtom 1.0 serializer: Now tested and takes more care to try to generate valid Atom 1.0 Turtle serializer:
Validate XSD integer, decimal and double literal
output. Emit special short forms only if the whole literal value is
consumed by RSS serializer:
Fixes for g++ XML Support ChangesRemoved generic calls to Use context-specific libslt security configuration to avoid
calling generic call Make libxml SAX2 structured errors register parser-specific
handler function In Other ChangesWin32 portability fixes from Lou Sakey:
Internal ChangesMore internal changes to be more resiliant after allocation failure (Lauri Aalto) Reorganised tests in source tree to pull out specific directories for RDF/XML, Turtle, etc. Use a DJ Bernstein hash to replace a linked list for storing a
stack of namespaces. This makes turtle parsing with lots of
namespaces (100s) much faster. Based on the initial patch in the bug. Use new internal
More fixes for compiling with C++ Move some more static data as constant to enable more efficient compilation - moves to data segment of object binary. Use memmove for overlapping copy, not memcpy when doing relative URI resolving. Raptor V2 Preparation ChangesLots of internal changes were made by Lauri Aalto preparing for
Raptor V2 to fully attach all static data and config to a new
NOTE: The method names here are illustrative of the final
V2 names but are not confirmed - These functions are not
supported in the 1.4.x series. Some methods will still be
altered for fields and ( To use the unsupported and experimental V2
functions, define Added Added raptor world class constructor
Added world class destructor:
Added new V2 methods: void raptor_world_set_libxslt_security_preferences(raptor_world *world, void *security_preferences) void raptor_world_set_libxml_flags(raptor_world *world, int flags) void raptor_error_handlers_init_v2(raptor_world* world, raptor_error_handlers* error_handlers); Added V2 methods that are versions of existing methods, named with _v2 suffix: int raptor_parsers_enumerate_v2(raptor_world* world, const unsigned int counter, const char **name, const char **label) int raptor_syntax_name_check_v2(raptor_world* world, const char *name); void raptor_print_locator_v2(raptor_world* world, FILE *stream, raptor_locator* locator); const char *raptor_locator_uri_v2(raptor_world* world, raptor_locator *locator); int raptor_features_enumerate_v2(raptor_world* world, const raptor_feature feature, const char **name, raptor_uri **uri, const char **label); int raptor_serializers_enumerate_v2(raptor_world* world, const unsigned int counter, const char **name, const char **label, const char **mime_type, const unsigned char **uri_string); int raptor_serializer_syntax_name_check_v2(raptor_world* world, const char *name); int raptor_serializer_features_enumerate_v2(raptor_world* world, const raptor_feature feature, const char **name, raptor_uri **uri, const char **label); Added world pointer to raptor_identifier object Added V2 identifier class constructor: raptor_identifier* raptor_new_identifier_v2(raptor_world* world, raptor_identifier_type type, raptor_uri *uri, raptor_uri_source uri_source, const unsigned char *id, const unsigned char *literal, raptor_uri *literal_datatype, const unsigned char *literal_language); Added V2 parser class method: raptor_parser* raptor_new_parser_for_content_v2(raptor_world* world, raptor_uri *uri, const char *mime_type, const unsigned char *buffer, size_t len, const unsigned char *identifier) raptor_world* raptor_parser_get_world(raptor_parser* rdf_parser); Added V2 serializer class constructor and method: raptor_serializer* raptor_new_serializer_v2(raptor_world* world, const char *name) raptor_world* raptor_serializer_get_world(raptor_serializer* rdf_serializer) Added V2 statement class Added V2 statement class methods: void raptor_print_statement_v2(const raptor_statement_v2 * statement, FILE *stream); unsigned char* raptor_statement_part_as_counted_string_v2(raptor_world* world, const void *term, raptor_identifier_type type, raptor_uri* literal_datatype, const unsigned char *literal_language, size_t* len_p); unsigned char* raptor_statement_part_as_string_v2(raptor_world* world, const void *term, raptor_identifier_type type, raptor_uri* literal_datatype, const unsigned char *literal_language); int raptor_statement_compare_v2(const raptor_statement_v2 *s1, const raptor_statement_v2 *s2); Added V2 uri class methods: unsigned char* raptor_uri_as_counted_string(raptor_uri *uri, size_t* len_p); raptor_uri* raptor_new_uri_v2(raptor_world* world, const unsigned char *uri_string); raptor_uri* raptor_new_uri_from_uri_local_name_v2(raptor_world* world, raptor_uri *uri, const unsigned char *local_name); raptor_uri* raptor_new_uri_relative_to_base_v2(raptor_world* world, raptor_uri *base_uri, const unsigned char *uri_string); raptor_uri* raptor_new_uri_from_id_v2(raptor_world* world, raptor_uri *base_uri, const unsigned char *id); raptor_uri* raptor_new_uri_for_rdf_concept_v2(raptor_world* world, const char *name); void raptor_free_uri_v2(raptor_world* world, raptor_uri *uri); int raptor_uri_equals_v2(raptor_world* world, raptor_uri* uri1, raptor_uri* uri2); int raptor_uri_compare_v2(raptor_world* world, raptor_uri* uri1, raptor_uri* uri2); raptor_uri* raptor_uri_copy_v2(raptor_world* world, raptor_uri *uri); unsigned char* raptor_uri_as_string_v2(raptor_world* world, raptor_uri *uri); unsigned char* raptor_uri_as_counted_string_v2(raptor_world* world, raptor_uri *uri, size_t* len_p); raptor_uri* raptor_new_uri_for_xmlbase_v2(raptor_world* world, raptor_uri* old_uri); raptor_uri* raptor_new_uri_for_retrieval(raptor_uri* old_uri); raptor_uri* raptor_new_uri_for_retrieval_v2(raptor_world* world, raptor_uri* old_uri); raptor_uri* raptor_new_uri_for_xmlbase_v2(raptor_world* world, raptor_uri* old_uri); raptor_uri* raptor_new_uri_for_retrieval_v2(raptor_world* world, raptor_uri* old_uri); unsigned char* raptor_uri_to_relative_counted_uri_string_v2(raptor_world* world, raptor_uri *base_uri, raptor_uri *reference_uri, size_t *length_p); unsigned char* raptor_uri_to_relative_uri_string_v2(raptor_world* world, raptor_uri *base_uri, raptor_uri *reference_uri); void raptor_uri_print_v2(raptor_world* world, const raptor_uri* uri, FILE *stream); unsigned char* raptor_uri_to_counted_string_v2(raptor_world* world, raptor_uri *uri, size_t *len_p); void raptor_uri_set_handler_v2(raptor_world* world, const raptor_uri_handler *handler, void *context); void raptor_uri_get_handler_v2(raptor_world* world, const raptor_uri_handler **handler, void **context); Added V2 www class methods: raptor_www *raptor_www_new_with_connection_v2(raptor_world* world, void* connection); Added V2 qname class methods: raptor_qname* raptor_new_qname_from_namespace_local_name_v2(raptor_world* world, raptor_namespace *ns, const unsigned char *local_name, const unsigned char *value); Added V2 namespace class methods: raptor_namespace_stack* raptor_new_namespaces_v2(raptor_world* world, raptor_simple_message_handler error_handler, void *error_data, int defaults); int raptor_namespaces_init_v2(raptor_world* world, raptor_namespace_stack *nstack, raptor_simple_message_handler error_handler, void *error_data, int defaults); Added V2 sequence class typedefs and methods: typedef void (raptor_sequence_free_handler_v2(void* context, void* object)); typedef void (raptor_sequence_print_handler_v2(void *context, void *object, FILE *fh)); raptor_sequence* raptor_new_sequence_v2(raptor_sequence_free_handler_v2* free_handler, raptor_sequence_print_handler_v2* print_handler, void* handler_context); void raptor_sequence_set_print_handler_v2(raptor_sequence *seq, raptor_sequence_print_handler_v2 *print_handler); Added V2 iostream class methods: int raptor_iostream_write_uri_v2(raptor_world* world, raptor_iostream *iostr, raptor_uri *uri); void raptor_iostream_write_statement_ntriples_v2(raptor_world* world, raptor_iostream* iostr, const raptor_statement *statement); Added V2 xml writer class methods: raptor_xml_writer* raptor_new_xml_writer_v2(raptor_world* world, raptor_namespace_stack *nstack, raptor_iostream* iostr, raptor_simple_message_handler error_handler, void *error_data, int canonicalize); int raptor_xml_writer_features_enumerate_v2(raptor_world* world, const raptor_feature feature, const char **name, raptor_uri **uri, const char **label); Raptor 1.4.18 ChangesFixed Issues:
Parser ChangesA new
RDFa
parser was added (name The RDFa test suite was added to the test and (via librdfa) Raptor passes all but 4 tests which fail due to different output xmlns attribute ordering (which does not matter to XML parsers). Serializer ChangesAdded new function
A new Atom Syndication Format 1.0 (RFC 4287) serializer was added (name RSS 1.0 serializer
Turtle serializer now respects the Abbreviated serializers (RDF/XML Abbrev and Turtle) now remove duplicate triples. Added feature Added QName Class ChangesAdded
Sequence Class Changes
Added URI Class Changes
XML Writer Class ChangesXML Writer allows adding newlines via
Added Other ChangesMany more resiliance checks were added. Removed all calls to abort() in code on fatal errors. This requires using setjmp and longjmp inside parsers built with flex and bison. The Turtle writer may optionally generate @base depending on flags. (This is used by Turtle serializer to handle the writeBaseURI feature) Tidied error messages for raptor_init() and raptor_finish() use a reference count to ensure initialising and terminating happen at most once each. Raptor 1.4.17 ChangesThe main changes to this release are: Added two new JSON serializers: resource-centric 'json' (Talis RDF/JSON) and triple-centric 'json-triples'. Made I/O Stream class Added a new public SAX2 API class Added new public error handlers structure
Several other API changes, fixes and improvements were made. Fixed Issues: I/O Stream class changesMade I/O Stream class
Added new write I/O Stream method
Serializer Class ChangesAdded two new JSON serializers (Dave B):
Added new serializer features for the JSON serializers (DaveB):
Example of using the resource-centric serializer while defining a callback: $ rapper -q -o json -f jsonCallback=foo https://librdf.org/raptor/raptor.rdf foo( { "https://librdf.org/raptor/#raptor" : { "http://usefulinc.com/ns/doap#description" : [ { ... Statement Class ChangesAdded Parser Class ChangesAdded new parser features to control HTTP headers in
web requests (Dave B, based on a patch in the bug):
Turtle parser:
QName Class ChangesAdded new methods SAX2 Class ChangesAdded new public SAX2 API class
Serializer Class ChangesAbbreviated serializers (RDF/XML-Abbrev and Turtle):
Turtle serializer:
URI Class ChangesUpdate URI resolving for RFC3986 changes (Dave B) WWW Class ChangesAdded new method XML Class ChangesAdded new method Portability and Resilience ChangesPass on error failures in parser and serializer factory construction. (Lauri) Abbreviated serializers (RDF/XML-abbrev and Turtle): low memory and allocation failure fixes. (Lauri) Altered API function signatures of
Portability fixes for RAPTOR_API and other macros. (Lauri) Removal of many sets of writable static data in N-Triples parser, URI class, Unicode NFC code, libxml support, Turtle writer and XML writer. (Lauri) Portability fixes for Turtle/N3 parsers and serializers, RDF/XML_Abbrev serializer: many low memory fixes and better out of memory errors. (Lauri) Other ChangesRewrote internal error log functions to use new error handlers structures and simplify the calls. (Dave B) Expanded internal Updated
Raptor 1.4.16 ChangesThe main changes to this release are: Provide 100% support for the GRDDL W3C Recommendation of 2007-09-11. The
Turtle
parser and serializer were updated to support
The Turtle and RDF/XML serializers had performance improvements for large graphs. Added a TRiG Parser based on Turtle with named graph support. Several other API changes, fixes and improvements were made. Fixed Issues:
Namespaces Class Changes
Parser Class Changes
Added These were added the GRDDL parser:
XML Element Class ChangesAdded
Unicode Class ChangesDefined a new URI Class ChangesAdded WWW Class Changes
Added
Added
Added Parser ChangesThe GRDDL parser/processor was substantially updated and now supports 100% of the Gleaning Resource Descriptions from Dialects of Languages (GRDDL) syntax, W3C Recommendation of 2007-09-11:
it also:
RDF/XML parser recognising was updated to just the start of the document for guessing if it should handle content and to try to avoid html URLs. RSS Tag soup parser recognising was updated to accept with the string 'feed' in the identifier. TRiG Parser was added based on the Turtle parser, adding named
graphs. It returns name graph URis via a callback set with new API
call Turtle parser added Serializer ChangesTurtle serialiser changes:
RDF/XML serialiser was changed to emit a legal empty RDF/XML document when no triples are serialised and to skip emitting statements with bad predicate uris rather than returning an error. RDF/XML Abbrev serialiser was changed to use an AVL tree rather than sequence for significant performance improvement for large serialisations.
|
Atom 1.0 term | Original term |
---|---|
atom:content | rss:description |
atom:id | rss:link |
atom:published | dc:date |
atom:rights | dc:rights |
atom:title | rss:title |
Apply the in-scope base URI (such as from xml:base
)
to atom 1.0 fields that take URI values:
atom:id
, atom:icon
and atom:logo
.
Added optional date parsing code to turn XML RSS date fields into ISO format ones, suitable for Atom and XML schema datatypes format. Will use library parsedate code from curl or INN if available.
XML RSS field pubDate
is now turned into Dublin Core
dc:date
field in the ISO format.
XML RSS field content
is turned into
content:encoded
in RDF triples on output with
escaping.
Updated to support Turtle version 2006-01-02 (announcement).
Switch qname, blank node and prefix definitions to SPARQL ones.
Check for illegal not-hexadecimal \u and \U escape values.
Fix greedy matching of long literals ("""....""") that ended on the last """ found rather than the first.
Added double and decimal constants.
Added optional +- sign to all numeric constants.
Allow \" escape inside long strings.
Take care to reset the generated raptor_statement
language and datatype fields when not used.
Added a new Atom 1.0 serializer (name atom) by parameterising the RSS 1.0 serializer.
Added a new Adobe XMP compatible serializer (name rdfxml-xmp) by parameterising the RDF/XML Abbreviated serializer. Patch provided by Sid Steward.
All serializers can be chosen at configure
time from
those available using configure option --enable-serializers
.
The RSS parser and serializer can now be independently enabled or disabled. The RSS serializer no longer requires an XML parser.
A new XML Writer feature
RAPTOR_FEATURE_WRITER_XML_VERSION
was added to allow
chosing XML 1.0 (value 10) or XML 1.1 output (value 11). This
feature is also accepted by serializers as an option and used by the
RDF/XML and RDF/XML-Abbrev serializers.
A new XML Writer feature
RAPTOR_FEATURE_WRITER_XML_DECLARATION
was added to allow
omitting the XML declaration (default true).
Added functions raptor_xml_any_escape_string()
and raptor_iostream_write_xml_any_escaped_string()
which take an XML version. The XML 1.0 functions give errors
when attempting to write #x1-#x1f (excluding #x9, #xA, #xD) or #x7F.
Added a new serializer using the Atom 1.0 format and namespace. This reads RDF triples in the RSS 1.0 model, along with any additional atom 1.0 properties and serializes an Atom 1.0 feed file.
Added a new serializer writing RDF/XML in the profile used by
Adobe XMP. Note that this does require RDF triples to be used in a
certain style; for example all triple subjects are the "current
documment" giving rdf:about=""
.
Fix a bug when adding a default path of / to a URI
in functions raptor_new_uri_for_xmlbase()
and raptor_new_uri_for_retrieval()
.
(Bug #0000045)
raptor_uri_equals was altered to accept NULL pointers, which do not compare equal to a non-NULL URI. NULL does equal NULL.
The internal SAX2 class was extensively changed so that remaining interdependencies with the RDF/XML parser were removed and it can now be re-used for other syntaxes cleanly. Several functions were modified or added.
Removed old and hardly-tested internal support for XML entity resolution (libxml only).
Various fixes for GCC 4 warnings.
Fix a couple of crashes in the RSS tag soup parser / serializer (Dave Beckett, Suzan Foster).
configure
now looks for the
libxslt/xslt.h
header as well as the
libxslt
library and disables XSLT and GRDDL support it
if is missing. This catches systems with the libraries without
headers as has happened on some OSX versions.
In serializers rdfxml and rdfxml-abbrev, report failure to serialize to RDF/XML if the predicate URI is not absolute.
Added --with-xslt-config
configure option
Added a new parser for
Gleaning Resource Descriptions from Dialects of Languages (GRDDL)
which allows reading XHTML and XML as RDF triples by using profiles
in the document that declare XSLT transforms from the XHTML/XML
content into RDF/XML which is the RDF content. It does not
support all the GRDDL styles, for example
dataview:namespaceTransformation
,
or perform recursive transformations.
The turtle parser now accepts """long literals"""
XML writer feature support were added in 1.4.5 and not documented.
The new functions are:
raptor_xml_writer_features_enumerate
,
raptor_xml_writer_set_feature
,
raptor_xml_writer_set_feature_string
,
raptor_xml_writer_get_feature
and
raptor_xml_writer_get_feature_string
.
The three XML writer features added are
\fBRAPTOR_FEATURE_WRITER_AUTO_INDENT\fR with boolean value (default true)
to auto-indent the XML,
\fBRAPTOR_FEATURE_WRITER_AUTO_EMPTY\fR with boolean value (default true)
to automatically generate empty elements if a start/end element sequence
has no content and
\fBRAPTOR_FEATURE_WRITER_INDENT_WIDTH\fR with an integer value (default 2)
to set the indenting level for the XML.
New build configuration and portability fixes for win32 (John Barstow)
Portability fixes for win32 - added
SIZEOF_UNSIGNED_SHORT
(Dave Viner, others)
Added a signing memory debugging system to aid checking when
raptor-allocated memory is freed in another library or vice-versa
enabled by --with-memory-signing
configure option
(defaults to on in maintainer mode).
Fixed a few internal malloc/frees to use RAPTOR_MALLOC / RAPTOR_FREE so that the above signed memory system worked.
RDF/XML serializer:
Use the maximal name when splitting a predicate.
Turn datatyped literals that are rdf:XMLLiteral into inline XML with
rdf:parseType="Literal"
rather than XML-escaped.
RDF/XML abbreviated serializer:
Fix a crash when there is a NULL base URI.
Use the maximal name when splitting a predicate.
Turn datatyped literals that are rdf:XMLLiteral into inline XML with
rdf:parseType="Literal"
rather than XML-escaped.
RSS tag soup parser:
Fix crash with unexpected use of alternate
attribute.
Update from Suzan Foster to reflect the latest status of the
enclosure vocabulary and allow multiple common items and fields.
RSS 1.0 serializer: Added RSS enclosures serializing.
grapper
example GTK program now stores the window
width and height using gconf2.
Added a new RDF/XML with abbreviations serializer
rdfxml-abbrev
written by Steve Shepard which handles
several of the abbreviations specified by the
RDF/XML Syntax Specification (Revised)
W3C Recommendation. It is suitable for writing small documents as
there are known scaling issues.
The RSS tag soup parser was updated to work better when there is no base URI given. It also now supports reading the RSS 1.1 format and turning it into RSS 1.0 model triples.
Deprecated raptor_ntriples_string_as_utf8_string
as
rather too internal to be useful, since it only works with a parser.
More fixes to work around the broken libxml2 on Apple OSX 10.3.x with inconsistent shared libraries / headers.
Experimental and incomplete Notation 3 parser - updated to match changes to Turtle. CVS changes only, not enabled in standard builds.
Make the RSS tag soup parser handle RSS 0.9 namespace elements by turning them into RSS 1.0.
Fix a couple of crashes in the RSS 1.0 serialiser when no base URI is used.
Make raptor_uri_to_relative_counted_uri_string
work when the base or reference URI have no paths such as like
http://example.org
Added portability fixes for Win32 to get Raptor 1.4.3 building with MS Visual Studio using expat and libcurl. The RAPTOR_INTERNAL define was moved to the build configuration and defines added for integral type sizes. Patch from Dave Viner (dviner at apache dot org).
A release with the major new feature of an XML writer API. This is now used along with a new supporting XML element class to improve the existing RDF/XML serializer and to provide a new RSS 1.0 serializer.
This API it is also used by the next release of Rasqal to provide serializing of query results to XML.
The new raptor_xml_writer
class functions added are:
raptor_new_xml_writer
(constructor),
raptor_free_xml_writer
(destructor),
raptor_xml_writer_empty_element
,
raptor_xml_writer_start_element
,
raptor_xml_writer_end_element
,
raptor_xml_writer_cdata
,
raptor_xml_writer_cdata_counted
,
raptor_xml_writer_raw
,
raptor_xml_writer_raw_counted
,
raptor_xml_writer_comment
and
raptor_xml_writer_comment_counted
.
The new raptor_xml_element
class functions added are:
raptor_new_xml_element
(constructor),
raptor_free_xml_element
(destructor),
raptor_xml_element_get_name
,
raptor_xml_element_set_attributes
,
raptor_xml_element_declare_namespace
and
raptor_iostream_write_xml_element
.
RSS tag soup parser now works with older libxml2s (2.5.10+), including the one shipped with some Apple OSX versions that has an inconsistent header file and library.
RSS tag soup parser recognises/scores more common XML RSS file names.
RSS tag soup parser turns XML RSS
<guid isPermaLink="true">val</guid>
into RDF/XML form <guid rdf:resource="val"/>
, leaving
the non isPermaLink form to be a literal value.
A bug was found in libxml2 that causes double expanding of XML entities in RDF/XML. This has been reported but cannot be worked around from raptor. The expat XML parser can be used as an alternative, as it does not have this problem. A test was added for this bug but it will not cause the test suite ('make check') to fail.
Added additional Turtle parser tests that cover Notation 3 syntax that is not part of the Turtle language.
Added
raptor_parser_set_feature_string
and
raptor_parser_get_feature_string
methods to set/get string feature values.
Added feature relative_uris
for serializers. This
is used by the RDF/XML serializer and enabled by default.
Added feature start_uri
for serializers with a string
value to set the start URI for serializing. Not used at present.
Added new methods raptor_serializer_features_enumerate
to list serializer features and functions to set/get serializer
feature integer or strings values:
raptor_serializer_set_feature
,
raptor_serializer_get_feature
,
raptor_serializer_set_feature_string
and
raptor_serializer_get_feature_string
.
Added raptor_serialize_set_namespace
to allow user
declaration of prefix/URI namespaces pairs as serializing hints.
the RDF/XML serializer was improved using the new XML Writer class so it now uses any user-declared namespace hints in it's output and emits relative URIs whenever possible. The latter was provided by a patch from René Puls.
A new RSS 1.0 serializer was added, using the new XML Writer class and using the same structures, classes and properties as the RSS tag soup parser.
Added relative URI generating code from a patch written by René Puls
and provide this with two new methods
raptor_uri_to_relative_uri_string
and
raptor_uri_to_relative_counted_uri_string
.
Added raptor_uri_print
to print a URI to a file handle.
Added methods raptor_uri_to_string
and
raptor_uri_to_counted_string
to return a URI as newly
allocated strings.
Many classes gained methods to write to iostreams, supporting the
new XML Writer class functionality. The added methods are:
raptor_iostream_write_namespace
,
raptor_iostream_write_ntriples_string
,
raptor_iostream_write_qname
,
raptor_iostream_write_statement_ntriples
,
raptor_iostream_write_stringbuffer
,
raptor_iostream_write_xml_element
and
raptor_iostream_write_xml_escaped_string
.
Added raptor_namespace_copy
copy
constructor and raptor_new_namespace_from_uri
constructor to build a namespace from a raptor_uri object.
Added utility function raptor_new_namespace_parts_from_string
to decode syntax of the form
xmlns:
prefix="
uri"
into prefix and uri string pairs.
Added raptor_namespaces_find_namespace_by_uri
method
for namespace stack to find a declared namespace by URI. This
complements raptor_namespaces_find_namespace
which
already provides searching by prefix.
Added several methods for checking characters forming
parts of XML 1.0 or XML 1.1 names:
raptor_unicode_is_xml10_namestartchar
,
raptor_unicode_is_xml11_namestartchar
,
raptor_unicode_is_xml10_namechar
and
raptor_unicode_is_xml11_namechar
.
Added a function raptor_utf8_check
to check that a
string is legal UTF-8 and all the encoded Unicode characters are in
the range U+0 <= character <= U+10FFFF
Added a function raptor_xml_name_check
to check that
a string is a legal XML name (1.0 or 1.1) as well as legal UTF-8.
Feature support: Added raptor_feature_value_type
to
determine value of a feature - either integer (most) or string.
XML QName class: Added raptor_qname_copy
copy
constructor.
Sequence class: Added raptor_sequence_join
to join two sequences of items, leaving one empty.
Statement class: Added raptor_statement_copy
copy
constructor and raptor_free_statement
destructor.
Previously these were internal to raptor.
The rapper
utility was modified to add a feature form:
-f xmlns:
PREFIX="
URI"
allowing the setting of output serializer namespaces.
The namespace URI string constants exported by raptor are now of type unsigned char*.
Make raptor_xml_escape_string
fail correctly when
given bad UTF-8 to escape.
Fixed a buffer overrun in decoding a URI scheme in
raptor_uri
constructors such as
raptor_new_uri
.
Fixed a crash in RSS enclosures crash when the url
attribute seen on a non-<enclosure>
element
raptor_xml_escape_string
return value has changed to
be an int, returning <0 on failure. This allows the empty string
encoding an empty string case to work and be distinguished from an
error.
A release with the major new feature of providing serializing of RDF triples to syntaxes. It also added a new support class for I/O streams and had other minor fixes.
Added a Raptor Serializer class (raptor_serializer
)
with similar style to Parser (raptor_parser
). Two
serializers are provided, for RDF/XML and N-Triples. The serializing
can be done to files, C FILE*
or to strings. The
raptor_iostream class that provides this also allows writing
to any other form by creating a custom iostream.
The new raptor_serializer class functions added are:
raptor_serializers_enumerate
,
raptor_serializer_syntax_name_check
,
raptor_new_serializer
,
raptor_free_serializer
,
raptor_serialize_start
,
raptor_serialize_start_to_filename
,
raptor_serialize_start_to_string
,
raptor_serialize_start_to_file_handle
,
raptor_serialize_statement
,
raptor_serialize_end
,
raptor_serializer_get_iostream
,
raptor_serializer_set_error_handler
,
raptor_serializer_set_warning_handler
and
raptor_serializer_get_locator
Added a Raptor I/O stream abstraction in
raptor_iostream
class to support serializing of RDF to
multiple output streams such as to filenames, to C standard I/O
FILE*
handles and to strings especially for
cross-language use. A raptor_iostream_handler
can
be used to construct a user-defined iostream.
The new raptor_iostream class functions added are:
raptor_new_iostream_from_handler
,
raptor_new_iostream_to_sink
,
raptor_new_iostream_to_filename
,
raptor_new_iostream_to_file_handle
,
raptor_new_iostream_to_string
,
raptor_free_iostream
,
raptor_iostream_write_bytes
,
raptor_iostream_write_byte
,
raptor_iostream_write_end
,
raptor_iostream_write_string
,
raptor_iostream_write_counted_string
,
raptor_iostream_get_bytes_written_count
,
raptor_iostream_write_decimal
and
raptor_iostream_format_hexadecimal
.
The rapper
utility was modified to use serializer
class so that the output formats supported are now N-Triples
(-o ntriples
) - the default, and RDF/XML (-o
rdfxml
).
Raptor now exports more static namespace URI strings for
general application use:
raptor_xml_namespace_uri
,
raptor_rdf_namespace_uri
,
raptor_rdf_schema_namespace_uri
,
raptor_xmlschema_datatypes_namespace_uri
,
raptor_owl_namespace_uri
,
and the length
raptor_rdf_namespace_uri_len
.
The raptor_stringbuffer class gained a new method
raptor_stringbuffer_copy_to_string
which allows efficient copy-out of a constructed string.
The raptor_www class gained a new method
raptor_www_fetch_to_string
to allow retrieving of
web content as a single string.
RSS tag soup parser gained support for generating triples for enclosures, after a patch from Suzan Foster. Changes made include correcting the enclosures namespace and tidying some memory leaks.
A release with major improvements along with several minor fixes.
Raptor's License was changed from LGPL 2.1/MPL 1.1 to LGPL 2.1/Apache 2
Thanks to Chris Pointon for several patches to make Raptor easier to build under Win32 which were applied, with some slight modifications.
Increased WWW content retrieval buffer size from 256 bytes to 4K since this was causing problems for even moderate size documents.
After testing raptor on a very large RDF/XML file with many
rdf:ID
values, the check for duplicate values was found
to be inefficient in memory and slow. The implementation was
improved to be more memory efficient and a new parser feature
check_rdf_id
was added to disable checking (default is
enabled).
Added a new Unicode NFC checker to replace the functionality
formally available by calling the GNOME glib function
g_utf8_normalize. This new checker is done via several tables and
adds approximately 50K to the object size of the library when
compiled on x86. This code and tables can be disabled with configure
option --disable-nfc-check
causing all checks to
succeed.
Fix the exporting of
raptor_xml_literal_datatype_uri_string
and
raptor_xml_literal_datatype_uri_string_len
as constants
for use by applications. Previously raptor.h wasn't doing this
correctly.
Added raptor_calloc_memory
for allocating zeroed
memory inside raptor, for use by applications passing memory in/out
of raptor.
Added a new configure option --enable-parsers
to
allow the selection of the required RDF parsers from any of those
supported (RDF/XML, Turtle, N-Triples, RSS tag soup).
Reorganised the sources to split parsing support from RDF/XML to support compiling without this parser.
Updated the RSS Tag Soup parser to start to handle the Atom 0.3 currently being standardised by the IETF Atom Publishing Format and Protocol working group.
Altered the Turtle parser to work with large source documents that exceeded bison limits. Thanks to Geoff Chappell for providing a fix for this.
Rewrote the URI parsing to create an internal structure and improved the relative URI resolving in preparation for future work such as potentially supporting URI canonicalisation such as proposed to be used by Atom.
A release with some minor fixes.
Added a new configure option
--with-expat-source=
DIR
to allow the use of external expat source trees in either the old or
newer directory structure style. (Patch from Mark Smith).
Added raptor_alloc_memory
for handlers that need to
allocate memory in the same heap as raptor uses for
raptor_free_memory
. This is mostly useful for allocating
memory that is freed by raptor in error, ID and statement handlers
on win32 which has separate heaps for different DLLs.
A bug was fixed where errors which happened when fetching WWW content were always printed to stderr. They are now passed to the main error routines which allows applications to retrieve them.
Accessor functions were added for parts of the public
raptor_locator
structure which makes it possible to get
structured error information from language bindings via Redland
(Patch from Edd Dumbill). The new functions are:
int raptor_locator_line(raptor_locator *locator);
int raptor_locator_column(raptor_locator *locator);
int raptor_locator_byte(raptor_locator *locator);
const char * raptor_locator_file(raptor_locator *locator);
const char * raptor_locator_uri(raptor_locator *locator);
The Unicode Normal Form C (NFC) checking via the GNOME glib
library function g_utf8_normalize
is broken, comparing
the data it says is failed against other NFC checkers. It is also
slower than need be since it is doing full normalizing rather than
just checking for NFC, and adds a rather large dependency for just
one function. A new portable checker will be added in a later
release.
A release primarily to fix some win32 and portability issues.
raptor.h now includes stdarg.h
Corrected the raptor_print_statement
declaration in
raptor.h for the argument statement to have one less 'const' which
matches the actual code.
Made several portability fixes for compiling natively on win32 which doesn't quite do POSIX or C99.
Changed the support for file: URIs and converting to and from
filenames. It now %-escapes spaces and % characters on conversion
to and from filenames with
raptor_uri_uri_string_to_filename
,
raptor_uri_uri_string_to_filename_fragment
and
raptor_uri_filename_to_uri_string
.
For Win32, more tests were added and the
format of URIs supported corrected to use the file:///c:
form rather than file://c|/
URIs that resolve to directories now return an error when lstat is available to check.
The Turtle parser was updated to only allow language with non-datatyped literals, allow a '_' immediately after a ':' in qnames and to make a bare ':' qname work correctly.
The Turtle parser was fixed to re-initialise correctly when performing multiple parsings. The other parsers already did this correctly.
Added a warning to the RDF/XML parser for unknown
rdf:parseType
values, when parsing in lax mode - which
is the default. It now tells the user when the parsing is working as
'Literal' mode by finding an unknown value. This is controlled by a
new parser feature warn_other_parsetypes which is default set true
in lax mode. Parser modes are controlled by the
raptor_set_parser_strict
method.
A release primarily to provide support for the new Rasqal RDF query library but with some new features and fixes.
Added a new constructor
raptor_new_parser_for_content
to guess the parser to use
from hints in URIs or content, using a new utility function
raptor_guess_parser_name
.
Additional checks were added to the RDF/XML parser for RDF-namespaced names in element and attributes and if they are forbidden giving an error otherwise if unknown, giving a warning.
The
Turtle
parser was updated to correct the collections syntax, allow '-' in
names and QNames and to add integer literals. This parser now correctly
uses raptor_generate_id
when a blank identifier name is
needed.
Completed parser feature support by adding raptor_get_feature
,
raptor_feature_from_uri
, and
raptor_features_enumerate
to get values and enable
discovery of supported features at run time.
raptor_set_feature
was changed to give return a success
value
Added a new method raptor_get_mime_type
to get the
MIME type of the syntax for a parser
raptor_parse_uri_with_connection
(which is called by
raptor_parse_uri
) now sets the HTTP Accept:
header to the MIME type of the parser in WWW requests using the new
raptor_www_set_http_accept()
.
rapper
changesAdded options -f
/--feature
for setting
features and -g
/--guess
for guessing syntax
from some content or identifiers. See rapper(1)
for all rapper options.
Added raptor_syntax_name_check
to check for valid
syntax language names.
Added raptor_free_memory
to free memory returned by
raptor functions.
Added Unicode utility functions raptor_unicode_char_to_utf8
and
raptor_utf8_to_unicode_char
.
Exported URI string raptor_xml_literal_datatype_uri_string
.
Deprecated raptor_print_statement_detailed
always
intended to be internal.
Added support to set the HTTP Accept:
header for curl
and libxml2 when retrieving HTTP content by the new
raptor_www_set_http_accept
method.
Added a utility class raptor_sequence
providing
simple sequences that can handle stacks and queues
Added a utility class raptor_stringbuffer
for constructing strings from substrings appended or prepended.
Release notes for 1.2.0 and earlier are in the NEWS page or ChangeLog