vanetsim.gui.helpers
Class VehicleTypeXML

java.lang.Object
  extended by vanetsim.gui.helpers.VehicleTypeXML

public class VehicleTypeXML
extends java.lang.Object

This class provides functions to read (getVehicleTypes()) and save (saveVehiclesTypes()) in xml


Field Summary
 java.util.ArrayList<VehicleType> types_
          The ArrayList types collects all VehicleTypes
 
Constructor Summary
VehicleTypeXML(java.lang.String path)
          If no path is set, the default path is used
 
Method Summary
 java.lang.String getDefaultPath()
          Gets the defaultPath.
 java.util.ArrayList<VehicleType> getVehicleTypes()
          Returns a ArrayList with all vehicle types found.
 void saveVehicleTypes(java.util.ArrayList<VehicleType> tmpList)
          Save all vehicle types in tmpList to the xmlPath_
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

types_

public java.util.ArrayList<VehicleType> types_
The ArrayList types collects all VehicleTypes

Constructor Detail

VehicleTypeXML

public VehicleTypeXML(java.lang.String path)
If no path is set, the default path is used

Method Detail

getVehicleTypes

public java.util.ArrayList<VehicleType> getVehicleTypes()
Returns a ArrayList with all vehicle types found.

Returns:
Arraylist with all vehicle types

saveVehicleTypes

public void saveVehicleTypes(java.util.ArrayList<VehicleType> tmpList)
Save all vehicle types in tmpList to the xmlPath_


getDefaultPath

public java.lang.String getDefaultPath()
Gets the defaultPath.

Returns:
String defaultPath_: the default path to save the vehicle types.