private static void CreateTypes(Namespace ns, IEnumerable<XType> types)
        {
            foreach (var type in types)
            {
                var typeInNamespace = new CodeType
                {
                    Name = type.Name,
                    Namespace = ns,
                    Metrics = CreateMetrics(type.Metrics.Metric),
                    Members = new List<CodeMember>()
                };

                CreateMembers(typeInNamespace, type.Members.Member);

                ns.Types.Add(typeInNamespace);
            }
        }
        private static void CreateMembers(CodeType type, IEnumerable<XMember> members)
        {
            foreach (var member in members)
            {
                var memberInType = new CodeMember
                {
                    Name = member.Name,
                    ParentType = type,
                    Metrics = CreateMetrics(member.Metrics.Metric)
                };

                type.Members.Add(memberInType);
            }
        }