Skip to content
This repository was archived by the owner on Jun 16, 2018. It is now read-only.
This repository was archived by the owner on Jun 16, 2018. It is now read-only.

Optimize parsing of Attributes #8

@skreutzer

Description

@skreutzer

If attributes aren't used, the parser still reads them and creates the attribute list in memory. This is probably unavoidable, because attributes must be read before the the end of the tag can be discovered. There's no need however to construct Attribute objects in memory if they will never be used. One way to optimize it could be to just store the characters until the end of the tags temporarily and only interpret them when an attribute is actually requested, but that could be of similar expense in terms of processing time and memory as the current method of parsing and constructing the objects. Another way could be an extension to the StAX API to specify for which elements Attributes need to be loaded (default to all, until a specific policy is set).

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