Skip to content
This repository was archived by the owner on Jan 7, 2021. It is now read-only.
This repository was archived by the owner on Jan 7, 2021. It is now read-only.

toXml is very slow when json is large #61

@idy

Description

@idy

In line 53 and line 59:
xml = toXml(elem, xml);

When pass the xml parameter to function toXml, xml will be copied, and the xml is all strings above current processing cursor. This is a O(n^2) complexity to parse json to xml, where n is the length of xml content.

It's better to create a class, and all data are appended to a private member this.xml. I will send a PR to this.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions