예제 #1
0
        private void addPackageBranch(Tree tree, ParsedPackageDependencyPair parsedPackageDependencyPair)
        {
            var branch = new Branch();

            if (parsedPackageDependencyPair.NeededPackage != null)
            {
                Branch.Append(branch, parsedPackageDependencyPair.NeededPackage);
            }
            Branch.Append(branch, parsedPackageDependencyPair.MainPackage);
            Tree.Append(tree, branch);
        }
예제 #2
0
 private void handleMainPackageIsNotInTree(Tree tree, Branch branchMainPackage, Branch branchNeededPackage,
                                           ParsedPackageDependencyPair parsedPackageDependencyPair)
 {
     if (parsedPackageDependencyPair.NeededPackage == null ||
         branchNeededPackage == null)
     {
         addPackageBranch(tree, parsedPackageDependencyPair);
     }
     else
     {
         Branch.Append(branchNeededPackage, parsedPackageDependencyPair.MainPackage);
     }
 }