Exemple #1
0
 /// <summary>
 /// Returns true if the node has the dependee of sNode.
 /// </summary>
 public bool HasDependee(DependencyNode sNode)
 {
     return(_linkedDependees.ContainsKey(sNode.ToString()));
 }
Exemple #2
0
 /// <summary>
 /// Returns true if the node has the dependency of tNode.
 /// </summary>
 public bool HasDependency(DependencyNode tNode)
 {
     return(_linkedDependency.ContainsKey(tNode.ToString()));
 }
Exemple #3
0
 /// <summary>
 /// Removes dependee from this
 /// </summary>
 /// <param name="dependee">The node to be removed from the Dependees.</param>
 /// <returns>True if the node was successfully removed from the set, false otherwise.</returns>
 public bool RemoveDependee(DependencyNode dependee)
 {
     return(Dependees.Remove(dependee));
 }
Exemple #4
0
 /// <summary>
 /// Removes dependent from this
 /// </summary>
 /// <param name="dependent">The node to be removed from the Dependents.</param>
 /// <returns>True if the node was successfully removed from the set, false otherwise.</returns>
 public bool RemoveDependent(DependencyNode dependent)
 {
     return(Dependents.Remove(dependent));
 }
Exemple #5
0
 /// <summary>
 /// Adds dependee to this
 /// </summary>
 /// <param name="dependee">The node to be added.</param>
 /// <returns>True if the node was successfully added, false otherwise.</returns>
 public bool AddDependee(DependencyNode dependee)
 {
     // HashSet does not allow duplicates.
     return(Dependees.Add(dependee));
 }
Exemple #6
0
 /// <summary>
 /// Constructs this to be a "copy" of node
 /// </summary>
 /// <param name="node">The node to be copied.</param>
 public DependencyNode(DependencyNode node) : this(node.Name)
 {
 }