init
This commit is contained in:
@@ -0,0 +1,35 @@
|
||||
using DTS.Common.Import.Interfaces;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Xml;
|
||||
|
||||
namespace DTS.Common.Import.XML
|
||||
{
|
||||
public class XMLParseMMECustomFineLoc1s : XMLParseBase
|
||||
{
|
||||
public XMLParseMMECustomFineLoc1s(XmlElement root, double importedVersion, Func<bool> isCancelled = null) : base(root, importedVersion, isCancelled)
|
||||
{
|
||||
}
|
||||
|
||||
public override void Parse(ref ImportObject importObject)
|
||||
{
|
||||
importObject.AddCustomFineLoc1s(ParseCustomFineLoc1s(_root));
|
||||
}
|
||||
|
||||
private IEnumerable<ISO.MMEFineLocations1> ParseCustomFineLoc1s(XmlElement root)
|
||||
{
|
||||
List<ISO.MMEFineLocations1> list = new List<ISO.MMEFineLocations1>();
|
||||
|
||||
foreach (var child in root.ChildNodes)
|
||||
{
|
||||
if (IsCancelled()) { return list; }
|
||||
if (child is XmlElement)
|
||||
{
|
||||
list.Add(ISO.MMEFineLocations1.ReadXML(child as XmlElement));
|
||||
}
|
||||
}
|
||||
return list;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user