Skip to content

Polygon should allow multiple innerBoundaryIs elements #6

@cbotman

Description

@cbotman

Hi there,

Thanks for your great work on this library.

I encountered a KML file that would not parse. The issue is the file had more than one Polygon->innerBoundaryIs element. I checked the KML spec, and this is indeed valid (and Google Earth loaded it up fine). https://developers.google.com/kml/documentation/kmlreference#polygon

The fix is easy to make. In com.ekito.simpleKML.model.Polygon.java, I changed:

    /** The inner boundary is. */
    @Element(required=false)
    private Boundary innerBoundaryIs;

to

    /** The inner boundary is list. */
    @ElementList(name="innerBoundaryIs", entry="innerBoundaryIs", inline=true, type=Boundary.class, required=false)
    private List<Boundary> innerBoundaryIsList;

And added the appropriate getter and setter for innerBoundaryIsList.

Hope this helps.

Thanks again.

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