Beispiel #1
0
        public virtual bool CheckPropertyValidity(eProperties i_PropertyToCheck, string i_ValueToCheck, ref string o_Error)
        {
            bool isValidProperty = false;

            switch (i_PropertyToCheck)
            {
            case eProperties.WheelMaker:
            {
                isValidProperty = Wheel.CheckWheelMakerName(i_ValueToCheck, ref o_Error);
                break;
            }

            case eProperties.WheelCurrentAirPressure:
            {
                isValidProperty = checkWheelPressure(i_ValueToCheck, ref o_Error);
                break;
            }

            case eProperties.Model:
            {
                isValidProperty = CheckModel(i_ValueToCheck, ref o_Error);
                break;
            }

            case eProperties.CurrentEnergyAmountPercentage:
            {
                isValidProperty = Vehicle.CheckRemainingEnergyValueValidity(i_ValueToCheck, this, ref o_Error);
                break;
            }

            default:
            {
                break;
            }
            }

            return(isValidProperty);
        }