incubator-jena-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Laurent Pellegrino (JIRA)" <>
Subject [jira] [Commented] (JENA-71) OutputLangUtils cannot encode Node.ANY
Date Thu, 16 Jun 2011 10:55:47 GMT


Laurent Pellegrino commented on JENA-71:

Unfortunately, this does not work when you have to serialize/deserialize two or more consecutives
Node_ANY nodes:

// serialize
OutputStreamWriter outWriter = new OutputStreamWriter(out);
OutputLangUtils.output(outWriter, Node.ANY, null);
OutputLangUtils.output(outWriter, Node.ANY, null);

// deserialize
Tokenizer tokenizer = TokenizerFactory.makeTokenizerUTF8(in);;;

After the first call to the first token is read (and the token that is read
is ANYANY and not only ANY). Then when you call next() a second time you get a NoSuchElementException
whereas you expect an another value. The patch that is enclosed was taking into account this
issue. However, I am not sure that the patch is the best solution for solving this issue.

> OutputLangUtils cannot encode Node.ANY
> --------------------------------------
>                 Key: JENA-71
>                 URL:
>             Project: Jena
>          Issue Type: Bug
>          Components: ARQ
>            Reporter: Laurent Pellegrino
>            Priority: Minor
>              Labels: arq, node.any
>         Attachments: JENA-71-r1131151.patch
> As stated in the mailing list (
and with JENA-70, Node.ANY cannot be encoded with OutputLangUtils.

This message is automatically generated by JIRA.
For more information on JIRA, see:


View raw message