Hello Marco,
yes, I think you are correct. I guess it could be that its not a
typo, but rather an old version which was not updated accordingly,
but it also doesn't matter as it is incorrect.
We would really appreciate if you would fix it.
Cheers
Dirk
On 11/13/2015 09:57 AM, Marco Lettere
wrote:
Hi all,
Just one question. The documentation page related to the json
module states:
Signatures |
json:serialize($input
as node()) as xs:string
json:serialize($input
as node(), $options as map(xs:string, xs:string)) as
xs:string |
Summary |
Serializes the node specified by $input as JSON, and
returns the result as xs:string instance. The node
is expected to conform to the output created by the json:parse() function. All
other items will be serialized as specified for the json output method of the official
specification.
Items can also be serialized as JSON if the Serialization
Parameter method is set to json .
The $options argument can be
used to control the way the input is serialized. |
But I think the signature should be for item()? for the
first parameter (since it allows also for maps) isn't it?
In effect
inspect:function(json:serialize#2)
returns
<function name="json:serialize" uri="http://basex.org/modules/json">
<argument type="item()" occurrence="?"/>
<argument type="item()" occurrence="?"/>
<return type="xs:string"/>
</function>
If it's confirmed I could proceed with fixing it.
Regards,
Marco.
--
Dirk Kirsten, BaseX GmbH, http://basexgmbh.de
|-- Firmensitz: Blarerstrasse 56, 78462 Konstanz
|-- Registergericht Freiburg, HRB: 708285, Geschäftsführer:
| Dr. Christian Grün, Dr. Alexander Holupirek, Michael Seiferle
`-- Phone: 0049 7531 28 28 676, Fax: 0049 7531 20 05 22