Пример #1
0
        public static void UnInstall(InstallTree tree, string[] arg)
        {
            Console.WriteLine("UnInstalling " + arg[0]);
            var result = InstallMethods.UnInstallNodeInTree(tree, arg[0]);

            if (result.Success)
            {
                Console.WriteLine("UnInstall Successful");
            }
            else
            {
                Console.WriteLine("UnInstall Unsuccessful");
            }
        }
Пример #2
0
        public static void Depend(InstallTree tree, string [] args)
        {
            Console.WriteLine("Adding " + args[0]);
            Console.WriteLine("Depending on " + String.Join(", ", args.Skip(1).ToArray()));
            var node     = new InstallNode(args[0]);
            var response = InstallMethods.AddNode(tree, args[0], args.Skip(1).ToList());

            if (response.Success)
            {
                Console.WriteLine("Dependency addition Successful");
            }
            else
            {
                Console.WriteLine("Dependency addition Failed");
            }
        }