所以我有一个看起来像这样的 url 的 xml:
<restaurantFoodImpls>
<RestaurantFood Price="1689.7594" ID="426" Description="quis egreddior glavans brevens, si eggredior. vobis e fecundio, fecundio, et quoque nomen gravum parte volcans">
<foodItem Name="Frances93" ID="548"/>
<restaurant Name="Alana59" PhoneNumber="7954016342" MobileNumber="372206-3626" LastName="Hickman" ID="1" FirstName="Gabrielle"/>
</RestaurantFood>
<RestaurantFood Price="14.225095" ID="520" Description="in plorum egreddior plorum e pladior in linguens essit. novum habitatio Versus plurissimum volcans linguens estum.">
<foodItem Name="Frances93" ID="548"/>
<restaurant Name="Alana59" PhoneNumber="7954016342" MobileNumber="372206-3626" LastName="Hickman" ID="1" FirstName="Gabrielle"/>
</RestaurantFood>
</restaurantFoodImpls>
如何使用 C# 将其解析为对象?
我曾尝试使用反序列化器,但我的问题是我希望从 XML 中的属性中读取元素的属性,但我无法获得它们。