I try to add interfaces to a node. I use "DiscoverInterfacesOnNode" and "AddInterfacesOnNode" methods. I get every interfaces and passed to XDocument object. I looked up "NPM.DiscoverAndAddInterfacesOnNode.ps1" example file and writing below code block. But I didn't understand how to convert my XDocument object to SolarWinds.NPM.Common.Models.Discovery.InterfaceDiscovery.DiscoveredLiteInterface array type. I have done something at another projects like that code but I can't do convert to this array type. I don't know I exactly describe my problem but the screenshot may help this.
I got the solution. I created an empty DiscoveredLiteInterface array. I processed every XElement array in XDoc (not as XDocument) as a DiscoveredLiteInterface. I can show schema like below.
XElement array at XDocument -> DiscoveredLiteInterface