Esempio n. 1
0
        // Only used for testing. Will be removed.
        public static IList <XDocument> Mappings(this Cfg.Configuration configuration)
        {
            var versionedClasses = new List <VersionedClass>();

            foreach (var pc in configuration.ClassMappings)
            {
                if (!VersionedClass.IsActsAsVersioned(pc))
                {
                    continue;
                }

                versionedClasses.Add(new VersionedClass(pc));
            }

            var documents = new List <XDocument>();
            var mapping   = configuration.BuildMapping();

            foreach (var vc in versionedClasses)
            {
                documents.Add(vc.BuildMappingDocument(configuration, mapping));
            }

            return(documents);
        }