Esempio n. 1
0
        public static DependencyGroup CreateWithEntry(DependencyInfo dependencyInfo)
        {
            var dependencyGroup = new DependencyGroup
            {
                DependencyName           = dependencyInfo.Name,
                VersionDependencyInfoMap = new Dictionary <string, List <DependencyInfo> >()
            };

            dependencyGroup.AddEntry(dependencyInfo);

            return(dependencyGroup);
        }
Esempio n. 2
0
        public static DependencyGroup CreateWithEntry(DependencyInfo dependencyInfo)
        {
            var dependencyGroup = new DependencyGroup
            {
                DependencyName = dependencyInfo.Name,
                VersionDependencyInfoMap = new Dictionary<string, List<DependencyInfo>>()
            };

            dependencyGroup.AddEntry(dependencyInfo);

            return dependencyGroup;
        }
Esempio n. 3
0
        private string GetDependencyGroupConflictMessage(DependencyGroup dependencyGroup)
        {
            StringBuilder sb = new StringBuilder();

            sb.Append($"Conflict for {dependencyGroup.DependencyName} in projects:{Environment.NewLine}");
            
            foreach (var version in dependencyGroup.VersionDependencyInfoMap.Keys)
            {
                var dependencyInfoList = dependencyGroup.VersionDependencyInfoMap[version];
                
                foreach (var dependencyInfo in dependencyInfoList)
                {
                    sb.Append($"Version: {dependencyInfo.Version} Path: {dependencyInfo.ProjectPath} {Environment.NewLine}");
                }
            }
            sb.Append(Environment.NewLine);

            return sb.ToString();
        }