AjScript.TypeUtilities.GetNamespaces C# (CSharp) Method

GetNamespaces() private static method

private static GetNamespaces ( ) : ICollection
return ICollection
        private static ICollection<string> GetNamespaces()
        {
            List<string> namespaces = new List<string>();

            LoadReferencedAssemblies();

            foreach (Assembly assembly in AppDomain.CurrentDomain.GetAssemblies())
                foreach (Type type in assembly.GetTypes())
                    if (!namespaces.Contains(type.Namespace))
                        namespaces.Add(type.Namespace);

            return namespaces;
        }