package de.hft.stuttgart.citygml.green.osm.jaxb;

import java.util.ArrayList;
import java.util.List;

import jakarta.xml.bind.annotation.XmlAttribute;
import jakarta.xml.bind.annotation.XmlElement;
import jakarta.xml.bind.annotation.XmlElements;

public class OsmWay {
	
	@XmlAttribute
	private String id;

	@XmlElement
	private Bounds bounds;

	@XmlElements(value = { @XmlElement(name = "nd", type = WayNode.class) })
	private List<WayNode> nodes;
	
	@XmlElements(value = { @XmlElement(name = "tag", type = OsmTag.class) })
	private List<OsmTag> tags;

	
	public List<OsmTag> getTags() {
		if (tags == null) {
			tags = new ArrayList<>();
		}
		return tags;
	}

	public String getId() {
		return id;
	}
	
	public Bounds getBounds() {
		return bounds;
	}

	public List<WayNode> getNodes() {
		if (nodes == null) {
			nodes = new ArrayList<>();
		}
		return nodes;
	}

}
