Equals

Equals(ResourceAssignment)

Returns a value indicating whether this instance is equal to a specified instance of the ResourceAssignment class.

public bool Equals(ResourceAssignment other)
ParameterTypeDescription
otherResourceAssignmentThe specified instance of the ResourceAssignment class to compare with this instance.

Return Value

True if the specified instance of the ResourceAssignment class has the same UID value as this instance; otherwise, false.

Examples

Shows how to check resource assignment equality.

var project = new Project(DataDir + "BaselineTD2010_3.mpp");

var resourceAssignment1 = project.ResourceAssignments.GetByUid(1);
var resourceAssignment2 = project.ResourceAssignments.GetByUid(1);

Console.WriteLine("Are resource assignments equal: " + resourceAssignment1.Equals(resourceAssignment2));

See Also


Equals(object)

Returns a value indicating whether this instance is equal to a specified object.

public override bool Equals(object obj)
ParameterTypeDescription
objObjectThe object to compare with this instance.

Return Value

True if o is a ResourceAssignment that assign the same resource and task as this instance; otherwise, false.

Examples

Shows how to check resource assignment equality.

var project = new Project(DataDir + "BaselineTD2010_3.mpp");

var resourceAssignment1 = project.ResourceAssignments.GetByUid(1);
var resourceAssignment2 = project.ResourceAssignments.GetByUid(1);

Console.WriteLine("Are resource assignments equal: " + resourceAssignment1.Equals(resourceAssignment2));

See Also