A4LGSharedFunctions.ConfigUtil.GetFlowAccumConfig C# (CSharp) Method

GetFlowAccumConfig() public static method

public static GetFlowAccumConfig ( ) : List
return List
        public static List<FlowLayerDetails> GetFlowAccumConfig()
        {
            XmlDocument xmld = getConfigAsXMLDoc();
            if (xmld == null) return null;
            XmlNodeList nodelist = default(XmlNodeList);
            XmlNode node = default(XmlNode);
            List<FlowLayerDetails> pEntries = null;
            FlowLayerDetails pSingleEntries = null;

            try
            {

                //Get the list of name nodes
                //nodelist = xmld.SelectNodes("LayerViewerConfig/Layers/Layer");
                nodelist = xmld.SelectNodes("configuration/FlowAccumulation/FlowLayerDetails");
                if (nodelist == null) { return null; }
                //Loop through the nodes
                pEntries = new List<FlowLayerDetails>();

                for (int i = 0; i < nodelist.Count; i++)
                {
                    node = nodelist.Item(i);

                    pSingleEntries = (FlowLayerDetails)Globals.DeserializeObject(node, typeof(FlowLayerDetails));
                    if (pSingleEntries != null)
                        pEntries.Add(pSingleEntries);

                }

                return pEntries;
            }
            catch// (Exception ex)
            {

                return null;

            }
            finally
            {

                xmld = null;
                nodelist = null;
                node = null;
                pSingleEntries = null;
            }
        }