fairyfly_therm.material.xmlutil module¶
Utilities to convert THERM XML files to Material objects.
- fairyfly_therm.material.xmlutil.extract_all_materials_from_xml_file(xml_file, gases=None)[source]¶
Extract all Material objects from a THERM XML file.
- Parameters:
xml_file – A path to an XML file containing objects Material objects.
gases – A dictionary with gas names as keys and Gas object instances as values. These will be used to reassign the gas that fills cavity materials. If None, only solid materials are extracted.
- Returns:
A tuple with two elements
solid_materials: A list of all SolidMaterial objects in the XML file as fairyfly_therm SolidMaterial objects.
cavity_materials: A list of all CavityMaterial objects in the XML file as fairyfly_therm CavityMaterial objects.