diff --git a/VectoCore/VectoCore/InputData/FileIO/XML/Declaration/NinjectModules/XMLDeclarationInputDataV210InjectModule.cs b/VectoCore/VectoCore/InputData/FileIO/XML/Declaration/NinjectModules/XMLDeclarationInputDataV210InjectModule.cs index 3d59c9d8a9e2b7554f30b029eee917d5bf40bd5c..da74caaa2a415b73e0033278ac5bbd6d8ce34963 100644 --- a/VectoCore/VectoCore/InputData/FileIO/XML/Declaration/NinjectModules/XMLDeclarationInputDataV210InjectModule.cs +++ b/VectoCore/VectoCore/InputData/FileIO/XML/Declaration/NinjectModules/XMLDeclarationInputDataV210InjectModule.cs @@ -137,7 +137,11 @@ namespace TUGraz.VectoCore.InputData.FileIO.XML.Declaration.NinjectModules Bind<IXMLAuxiliaryReader>().To<XMLComponentReaderV210_Lorry>() .Named(XMLComponentReaderV210_Lorry.AUXILIARIES_READER_HEV_P_QUALIFIED_XSD_TYPE); - Bind<IXMLComponentReader>().To<XMLComponentReaderV210_PrimaryBus>().Named(XMLComponentReaderV210_PrimaryBus.QUALIFIED_XSD_TYPE); + Bind<IXMLAuxiliaryReader>().To<XMLComponentReaderV210_Lorry>() + .Named(XMLComponentReaderV210_Lorry.AUXILIARIES_READER_HEV_S2_QUALIFIED_XSD_TYPE); + + Bind<IXMLComponentReader>() + .To<XMLComponentReaderV210_PrimaryBus>().Named(XMLComponentReaderV210_PrimaryBus.QUALIFIED_XSD_TYPE); Bind<IXMLADASReader>() .To<XMLADASReaderV210>().Named(XMLADASReaderV210.QUALIFIED_XSD_TYPE_CONVENTIONAL); diff --git a/VectoCore/VectoCore/InputData/FileIO/XML/Declaration/Reader/Impl/XMLComponentReader.cs b/VectoCore/VectoCore/InputData/FileIO/XML/Declaration/Reader/Impl/XMLComponentReader.cs index d6720de18c35c0d1bd362290ddb00f47cfbae249..270fcea4ac6a3e7d237c07cfa2771ae4f8b45353 100644 --- a/VectoCore/VectoCore/InputData/FileIO/XML/Declaration/Reader/Impl/XMLComponentReader.cs +++ b/VectoCore/VectoCore/InputData/FileIO/XML/Declaration/Reader/Impl/XMLComponentReader.cs @@ -365,6 +365,7 @@ namespace TUGraz.VectoCore.InputData.FileIO.XML.Declaration.Reader.Impl //public new const string AXLE_READER_TYPE = "AxleDataDeclarationType"; public new const string AUX_READER_TYPE = "AUX_Conventional_LorryDataType"; public const string AUX_HEV_P_READER_TYPE = "AUX_HEV-P_LorryDataType"; + public const string AUX_HEV_S2_READER_TYPE = "AUX_HEV-S_LorryDataType"; public new static readonly string QUALIFIED_XSD_TYPE = XMLHelper.CombineNamespace(NAMESPACE_URI.NamespaceName, XSD_TYPE); @@ -373,6 +374,7 @@ namespace TUGraz.VectoCore.InputData.FileIO.XML.Declaration.Reader.Impl //public new static readonly string GEARBOX_READER_QUALIFIED_XSD_TYPE = XMLHelper.CombineNamespace(NAMESPACE_URI, GEARBOX_READER_TYPE); public new static readonly string AUXILIARIES_READER_QUALIFIED_XSD_TYPE = XMLHelper.CombineNamespace(NAMESPACE_URI, AUX_READER_TYPE); public static readonly string AUXILIARIES_READER_HEV_P_QUALIFIED_XSD_TYPE = XMLHelper.CombineNamespace(NAMESPACE_URI, AUX_HEV_P_READER_TYPE); + public static readonly string AUXILIARIES_READER_HEV_S2_QUALIFIED_XSD_TYPE = XMLHelper.CombineNamespace(NAMESPACE_URI, AUX_HEV_S2_READER_TYPE); public XMLComponentReaderV210_Lorry(IXMLDeclarationVehicleData vehicle, XmlNode componentsNode) : base( diff --git a/VectoCore/VectoCoreTest/XML/XMLDeclarationInputv210.cs b/VectoCore/VectoCoreTest/XML/XMLDeclarationInputv210.cs index 4b6974f0d9694d9c2a4225d551f269c3fb27f14a..c508e1b4960b829727164d0e0e35223260f8f0f4 100644 --- a/VectoCore/VectoCoreTest/XML/XMLDeclarationInputv210.cs +++ b/VectoCore/VectoCoreTest/XML/XMLDeclarationInputv210.cs @@ -595,13 +595,20 @@ namespace TUGraz.VectoCore.Tests.XML Assert.AreEqual(2, vehicle.Components.ElectricMachines.Entries.Count); TestElectricMachines(vehicle.Components.ElectricMachines.Entries); Assert.IsNotNull(vehicle.Components.GearboxInputData); - + TestTorqueConverter(vehicle); Assert.IsNotNull(vehicle.Components.AngledriveInputData);//optional Assert.IsNotNull(vehicle.Components.RetarderInputData);//optional Assert.IsNotNull(vehicle.Components.AxleGearInputData); Assert.IsNotNull(vehicle.Components.AxleWheels); Assert.IsNotNull(vehicle.Components.AuxiliaryInputData); Assert.IsNull(vehicle.Components.BusAuxiliaries); + Assert.IsNotNull(vehicle.Components.AirdragInputData); + Assert.IsNotNull(vehicle.Components.ElectricStorage); + Assert.IsNotNull(vehicle.Components.PTOTransmissionInputData); + Assert.IsNull(vehicle.CargoVolume); + Assert.IsNotNull(vehicle.TorqueLimits); + Assert.IsNotNull(vehicle.ElectricMotorTorqueLimits);//Vehicle EM Drive Limits + Assert.IsNull(vehicle.MaxPropulsionTorque);//Vehicle Max Prop. Limit } private void TestElectricMachines(IList<ElectricMachineEntry<IElectricMotorDeclarationInputData>> eMachines) @@ -622,14 +629,16 @@ namespace TUGraz.VectoCore.Tests.XML { Assert.AreEqual(1, eMachine.Count); TestElectricMachinesData(eMachine); - TestADC(eMachine.ADC); + if (eMachine.ADC != null) + TestADC(eMachine.ADC); } private void TestElectricMachine(ElectricMachineEntry<IElectricMotorDeclarationInputData> eMachine) { Assert.AreEqual(1, eMachine.Count); TestElectricMachinesData(eMachine); - TestADC(eMachine.ADC); + if(eMachine.ADC != null) + TestADC(eMachine.ADC); } private void TestADC(IADCDeclarationInputData adcData)