package massim.protocol.scenario.city.data;

import massim.protocol.DynamicWorldData;

import javax.xml.bind.annotation.*;
import java.util.List;

/**
 * Holds the world data that may change in each step.
 */
@XmlRootElement(name="dynamicCity")
@XmlAccessorType(XmlAccessType.NONE)
public class DynamicCityData extends DynamicWorldData {

    @XmlElement(name="entity")
    public List<EntityData> entities;

    @XmlElement(name="shop")
    public List<ShopData> shops;

    @XmlElement(name="workshop")
    public List<WorkshopData> workshops;

    @XmlElement(name="chargingStation")
    public List<ChargingStationData> chargingStations;

    @XmlElement(name="dump")
    public List<DumpData> dumps;

    @XmlElement(name="job")
    public List<JobData> jobs;

    @XmlElement(name="storage")
    public List<StorageData> storage;

    @XmlElement(name="resourceNode")
    public List<ResourceNodeData> resourceNodes;

    /**
     * For jaxb
     */
    private DynamicCityData(){
        super();
    }

    public DynamicCityData(int step, List<EntityData> entities, List<ShopData> shops, List<WorkshopData> workshops,
                           List<ChargingStationData> stations, List<DumpData> dumps, List<ResourceNodeData> resourceNodes, List<JobData> jobs,
                           List<StorageData> storage){
        super(step);
        this.entities = entities;
        this.shops = shops;
        this.workshops = workshops;
        this.chargingStations = stations;
        this.dumps = dumps;
        this.jobs = jobs;
        this.storage = storage;
        this.resourceNodes = resourceNodes;
    }
}

@@ -827,16 +827,17 @@
  storage
+s
 ;%0A%0A    @
@@ -1316,16 +1316,17 @@
  storage
+s
 )%7B%0A     
@@ -1555,16 +1555,17 @@
 .storage
+s
  = stora
@@ -1566,16 +1566,17 @@
  storage
+s
 ;%0A      

fix inconsistent internal naming of storages