Class Vehicletype


  • public class Vehicletype
    extends java.lang.Object
    Author:
    Mario Krumnow, Evamarie Wiessner
    • Constructor Summary

      Constructors 
      Constructor Description
      Vehicletype()  
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static SumoCommand getAccel​(java.lang.String typeID)
      Returns the maximum acceleration of the named vehicle class.
      static SumoCommand getApparentDecel​(java.lang.String typeID)
      Returns The preferred lateral alignment of the type
      static SumoCommand getColor​(java.lang.String typeID)
      Returns the vehicle type's color.
      static SumoCommand getDecel​(java.lang.String typeID)
      Returns the maximum deceleration of the names vehicle type.
      static SumoCommand getEmergencyDecel​(java.lang.String typeID)
      Returns the maximal physically possible deceleration in m/s^2 of vehicles of this type.
      static SumoCommand getEmissionClass​(java.lang.String typeID)
      Returns the emission class of the named vehicle type.
      static SumoCommand getHeight​(java.lang.String typeID)
      Returns the height in m of vehicles of this type.
      static SumoCommand getIDCount()
      Returns the number of all vehicle types in the network.
      static SumoCommand getIDList()
      Returns a list of all known vehicle types.
      static SumoCommand getImperfection​(java.lang.String typeID)
      getImperfection
      static SumoCommand getLateralAlignment​(java.lang.String typeID)
      Returns The preferred lateral alignment of the type
      static SumoCommand getLength​(java.lang.String typeID)
      Returns the length of the named vehicle type.
      static SumoCommand getMaxSpeed​(java.lang.String typeID)
      Return the maximum speed of the named vehicle type.
      static SumoCommand getMaxSpeedLat​(java.lang.String typeID)
      Returns the maximum lateral speed in m/s of this type.
      static SumoCommand getMinGap​(java.lang.String typeID)
      Returns the minimum headway gap of the named vehicle type.
      static SumoCommand getMinGapLat​(java.lang.String typeID)
      Returns The desired lateral gap of this type at 50km/h in m
      static SumoCommand getParameter​(java.lang.String typeID, java.lang.String param)
      Returns the chosen parameter
      static SumoCommand getShapeClass​(java.lang.String typeID)
      getShapeClass
      static SumoCommand getSpeedDeviation​(java.lang.String typeID)
      Returns the speed deviation of the named vehicle type.
      static SumoCommand getSpeedFactor​(java.lang.String typeID)
      Return the speed factor of the names vehicle type.
      static SumoCommand getTau​(java.lang.String typeID)
      getTau
      static SumoCommand getVehicleClass​(java.lang.String typeID)
      Returns the vehicle class of the names vehicle type.
      static SumoCommand getWidth​(java.lang.String typeID)
      Returns the width of the named vehicle type.
      static SumoCommand setAccel​(java.lang.String typeID, double accel)
      Sets the vehicle type's wished maximum acceleration to the given value.
      static SumoCommand setApparentDecel​(java.lang.String typeID, double decel)
      Sets the apparent deceleration in m/s^2 of vehicles of this type.
      static SumoCommand setColor​(java.lang.String typeID, SumoColor color)
      Sets the vehicle type's color.
      static SumoCommand setDecel​(java.lang.String typeID, double decel)
      Sets the vehicle type's wished maximum deceleration to the given value.
      static SumoCommand setEmergencyDecel​(java.lang.String typeID, double decel)
      Sets the maximal physically possible deceleration in m/s^2 of vehicles of this type.
      static SumoCommand setEmissionClass​(java.lang.String typeID, java.lang.String clazz)
      Sets the vehicle type's emission class to the given value.
      static SumoCommand setHeight​(java.lang.String typeID, double height)
      Sets the height in m of vehicles of this type.
      static SumoCommand setImperfection​(java.lang.String typeID, double imperfection)
      setImperfection
      static SumoCommand setLateralAlignment​(java.lang.String typeID, java.lang.String latAlignment)
      Sets the preferred lateral alignment of this type.
      static SumoCommand setLength​(java.lang.String typeID, double length)
      Sets the vehicle type's length to the given value.
      static SumoCommand setMaxSpeed​(java.lang.String typeID, double speed)
      Sets the vehicle type's maximum speed to the given value.
      static SumoCommand setMaxSpeedLat​(java.lang.String typeID, double speed)
      Sets the maximum lateral speed of this type.
      static SumoCommand setMinGap​(java.lang.String typeID, double minGap)
      Sets the vehicle type's minimum headway gap to the given value.
      static SumoCommand setMinGapLat​(java.lang.String typeID, double minGapLat)
      setImperfection
      static SumoCommand setParameter​(java.lang.String typeID, java.lang.String param, java.lang.String value)
      Sets the chosen parameter
      static SumoCommand setShapeClass​(java.lang.String typeID, java.lang.String clazz)
      setShapeClass
      static SumoCommand setSpeedDeviation​(java.lang.String typeID, double deviation)
      Sets the vehicle type's speed deviation to the given value.
      static SumoCommand setSpeedFactor​(java.lang.String typeID, double factor)
      Sets the vehicle type's speed factor to the given value.
      static SumoCommand setTau​(java.lang.String typeID, double tau)
      setTau
      static SumoCommand setVehicleClass​(java.lang.String typeID, java.lang.String clazz)
      Sets the vehicle type's vehicle class to the given value.
      static SumoCommand setWidth​(java.lang.String typeID, double width)
      Sets the vehicle type's width to the given value.
      static SumoCommand setWidth​(java.lang.String typeID, java.lang.String newTypeID)
      Duplicates the vType with ID origTypeID.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • Vehicletype

        public Vehicletype()
    • Method Detail

      • getAccel

        public static SumoCommand getAccel​(java.lang.String typeID)
        Returns the maximum acceleration of the named vehicle class.
        Parameters:
        typeID - type id
        Returns:
        acceleration
      • getIDCount

        public static SumoCommand getIDCount()
        Returns the number of all vehicle types in the network.
        Returns:
        number of vehicle types
      • getColor

        public static SumoCommand getColor​(java.lang.String typeID)
        Returns the vehicle type's color.
        Parameters:
        typeID - type id
        Returns:
        color color
      • getDecel

        public static SumoCommand getDecel​(java.lang.String typeID)
        Returns the maximum deceleration of the names vehicle type.
        Parameters:
        typeID - type id
        Returns:
        deceleration
      • getEmergencyDecel

        public static SumoCommand getEmergencyDecel​(java.lang.String typeID)
        Returns the maximal physically possible deceleration in m/s^2 of vehicles of this type.
        Parameters:
        typeID - type id
        Returns:
        deceleration
      • getLateralAlignment

        public static SumoCommand getLateralAlignment​(java.lang.String typeID)
        Returns The preferred lateral alignment of the type
        Parameters:
        typeID - type id
        Returns:
        deceleration
      • getHeight

        public static SumoCommand getHeight​(java.lang.String typeID)
        Returns the height in m of vehicles of this type.
        Parameters:
        typeID - type id
        Returns:
        deceleration
      • getApparentDecel

        public static SumoCommand getApparentDecel​(java.lang.String typeID)
        Returns The preferred lateral alignment of the type
        Parameters:
        typeID - type id
        Returns:
        deceleration
      • getMinGapLat

        public static SumoCommand getMinGapLat​(java.lang.String typeID)
        Returns The desired lateral gap of this type at 50km/h in m
        Parameters:
        typeID - type id
        Returns:
        deceleration
      • getMaxSpeedLat

        public static SumoCommand getMaxSpeedLat​(java.lang.String typeID)
        Returns the maximum lateral speed in m/s of this type.
        Parameters:
        typeID - type id
        Returns:
        deceleration
      • getEmissionClass

        public static SumoCommand getEmissionClass​(java.lang.String typeID)
        Returns the emission class of the named vehicle type.
        Parameters:
        typeID - type id
        Returns:
        emission class
      • getIDList

        public static SumoCommand getIDList()
        Returns a list of all known vehicle types.
        Returns:
        list of vechicle types
      • getImperfection

        public static SumoCommand getImperfection​(java.lang.String typeID)
        getImperfection
        Parameters:
        typeID - type id
        Returns:
        imperfection
      • getLength

        public static SumoCommand getLength​(java.lang.String typeID)
        Returns the length of the named vehicle type.
        Parameters:
        typeID - type id
        Returns:
        length
      • getMaxSpeed

        public static SumoCommand getMaxSpeed​(java.lang.String typeID)
        Return the maximum speed of the named vehicle type.
        Parameters:
        typeID - type id
        Returns:
        max speed
      • getMinGap

        public static SumoCommand getMinGap​(java.lang.String typeID)
        Returns the minimum headway gap of the named vehicle type.
        Parameters:
        typeID - type id
        Returns:
        min gap
      • getParameter

        public static SumoCommand getParameter​(java.lang.String typeID,
                                               java.lang.String param)
        Returns the chosen parameter
        Parameters:
        typeID - a string identifying the vehicle type
        param - a string identifying the parameter
        Returns:
        the specific parameter
      • setParameter

        public static SumoCommand setParameter​(java.lang.String typeID,
                                               java.lang.String param,
                                               java.lang.String value)
        Sets the chosen parameter
        Parameters:
        vehID - a string identifying the vehicle
        param - a string identifying the parameter
        value - a string identifying the new value
        Returns:
        SumoCommand
      • getShapeClass

        public static SumoCommand getShapeClass​(java.lang.String typeID)
        getShapeClass
        Parameters:
        typeID - type id
        Returns:
        shape class
      • getSpeedDeviation

        public static SumoCommand getSpeedDeviation​(java.lang.String typeID)
        Returns the speed deviation of the named vehicle type.
        Parameters:
        typeID - type id
        Returns:
        speed deviation
      • getSpeedFactor

        public static SumoCommand getSpeedFactor​(java.lang.String typeID)
        Return the speed factor of the names vehicle type.
        Parameters:
        typeID - type id
        Returns:
        speed factor
      • getTau

        public static SumoCommand getTau​(java.lang.String typeID)
        getTau
        Parameters:
        typeID - type id
        Returns:
        tau
      • getVehicleClass

        public static SumoCommand getVehicleClass​(java.lang.String typeID)
        Returns the vehicle class of the names vehicle type.
        Parameters:
        typeID - type id
        Returns:
        vehicle class
      • getWidth

        public static SumoCommand getWidth​(java.lang.String typeID)
        Returns the width of the named vehicle type.
        Parameters:
        typeID - type id
        Returns:
        width
      • setAccel

        public static SumoCommand setAccel​(java.lang.String typeID,
                                           double accel)
        Sets the vehicle type's wished maximum acceleration to the given value.
        Parameters:
        typeID - type id
        accel - acceleration
        Returns:
        SumoCommand
      • setColor

        public static SumoCommand setColor​(java.lang.String typeID,
                                           SumoColor color)
        Sets the vehicle type's color.
        Parameters:
        typeID - type id
        color - color
        Returns:
        SumoCommand
      • setDecel

        public static SumoCommand setDecel​(java.lang.String typeID,
                                           double decel)
        Sets the vehicle type's wished maximum deceleration to the given value.
        Parameters:
        typeID - type id
        decel - deceleration
        Returns:
        SumoCommand
      • setEmissionClass

        public static SumoCommand setEmissionClass​(java.lang.String typeID,
                                                   java.lang.String clazz)
        Sets the vehicle type's emission class to the given value.
        Parameters:
        typeID - type id
        clazz - emission class
        Returns:
        SumoCommand
      • setMinGapLat

        public static SumoCommand setMinGapLat​(java.lang.String typeID,
                                               double minGapLat)
        setImperfection
        Parameters:
        typeID - type id
        minGapLat - minGapLat
        Returns:
        SumoCommand
      • setMaxSpeedLat

        public static SumoCommand setMaxSpeedLat​(java.lang.String typeID,
                                                 double speed)
        Sets the maximum lateral speed of this type.
        Parameters:
        typeID - type id
        speed - speed
        Returns:
        SumoCommand
      • setApparentDecel

        public static SumoCommand setApparentDecel​(java.lang.String typeID,
                                                   double decel)
        Sets the apparent deceleration in m/s^2 of vehicles of this type.
        Parameters:
        typeID - type id
        decel - decel
        Returns:
        SumoCommand
      • setImperfection

        public static SumoCommand setImperfection​(java.lang.String typeID,
                                                  double imperfection)
        setImperfection
        Parameters:
        typeID - type id
        imperfection - imperfection
        Returns:
        SumoCommand
      • setLateralAlignment

        public static SumoCommand setLateralAlignment​(java.lang.String typeID,
                                                      java.lang.String latAlignment)
        Sets the preferred lateral alignment of this type.
        Parameters:
        typeID - type id
        latAlignment - latAlignment
        Returns:
        SumoCommand
      • setHeight

        public static SumoCommand setHeight​(java.lang.String typeID,
                                            double height)
        Sets the height in m of vehicles of this type.
        Parameters:
        typeID - type id
        height - height
        Returns:
        SumoCommand
      • setEmergencyDecel

        public static SumoCommand setEmergencyDecel​(java.lang.String typeID,
                                                    double decel)
        Sets the maximal physically possible deceleration in m/s^2 of vehicles of this type.
        Parameters:
        typeID - type id
        decel - decel
        Returns:
        SumoCommand
      • setLength

        public static SumoCommand setLength​(java.lang.String typeID,
                                            double length)
        Sets the vehicle type's length to the given value.
        Parameters:
        typeID - type id
        length - length
        Returns:
        SumoCommand
      • setMaxSpeed

        public static SumoCommand setMaxSpeed​(java.lang.String typeID,
                                              double speed)
        Sets the vehicle type's maximum speed to the given value.
        Parameters:
        typeID - type id
        speed - speed
        Returns:
        SumoCommand
      • setMinGap

        public static SumoCommand setMinGap​(java.lang.String typeID,
                                            double minGap)
        Sets the vehicle type's minimum headway gap to the given value.
        Parameters:
        typeID - type id
        minGap - minimum gap
        Returns:
        SumoCommand
      • setShapeClass

        public static SumoCommand setShapeClass​(java.lang.String typeID,
                                                java.lang.String clazz)
        setShapeClass
        Parameters:
        typeID - type id
        clazz - shape class
        Returns:
        SumoCommand
      • setSpeedDeviation

        public static SumoCommand setSpeedDeviation​(java.lang.String typeID,
                                                    double deviation)
        Sets the vehicle type's speed deviation to the given value.
        Parameters:
        typeID - type id
        deviation - deviation
        Returns:
        SumoCommand
      • setSpeedFactor

        public static SumoCommand setSpeedFactor​(java.lang.String typeID,
                                                 double factor)
        Sets the vehicle type's speed factor to the given value.
        Parameters:
        typeID - type id
        factor - factor
        Returns:
        SumoCommand
      • setTau

        public static SumoCommand setTau​(java.lang.String typeID,
                                         double tau)
        setTau
        Parameters:
        typeID - type id
        tau - tau
        Returns:
        SumoCommand
      • setVehicleClass

        public static SumoCommand setVehicleClass​(java.lang.String typeID,
                                                  java.lang.String clazz)
        Sets the vehicle type's vehicle class to the given value.
        Parameters:
        typeID - type id
        clazz - vehicle class
        Returns:
        SumoCommand
      • setWidth

        public static SumoCommand setWidth​(java.lang.String typeID,
                                           double width)
        Sets the vehicle type's width to the given value.
        Parameters:
        typeID - type id
        width - width
        Returns:
        SumoCommand
      • setWidth

        public static SumoCommand setWidth​(java.lang.String typeID,
                                           java.lang.String newTypeID)
        Duplicates the vType with ID origTypeID. The newly created vType is assigned the ID newTypeID
        Parameters:
        typeID - type id
        newTypeID - newTypeID
        Returns:
        SumoCommand