示例#1
0
        private void AddChildren(ProjectCataloguesNode projectCataloguesNode, DescendancyList descendancy)
        {
            HashSet <object> children = new HashSet <object>();

            foreach (ExtractableDataSet projectSpecificEds in ExtractableDataSets.Where(eds => eds.Project_ID == projectCataloguesNode.Project.ID))
            {
                children.Add(projectSpecificEds.Catalogue);
                AddChildren((Catalogue)projectSpecificEds.Catalogue, descendancy.Add(projectSpecificEds.Catalogue));
            }

            AddToDictionaries(children, descendancy);
        }
示例#2
0
        private void AddChildren(ProjectCataloguesNode projectCataloguesNode, DescendancyList descendancy)
        {
            HashSet <object> children = new HashSet <object>();

            foreach (ExtractableDataSet projectSpecificEds in ExtractableDataSets.Where(eds => eds.Project_ID == projectCataloguesNode.Project.ID))
            {
                var cata = (Catalogue)projectSpecificEds.Catalogue;

                // cata will be null if it has been deleted from the database
                if (cata != null)
                {
                    children.Add(cata);
                    AddChildren(cata, descendancy.Add(projectSpecificEds.Catalogue));
                }
            }

            AddToDictionaries(children, descendancy);
        }