Equals() public method

public Equals ( object o ) : bool
o object
return bool
Exemplo n.º 1
0
 public static void ApplicationDirectoryMembershipConditionCallMethods()
 {
     ApplicationDirectoryMembershipCondition admc = new ApplicationDirectoryMembershipCondition();
     bool check = admc.Check(new Evidence());
     IMembershipCondition obj = admc.Copy();
     check = admc.Equals(new object());
     int hash = admc.GetHashCode();
     string str = admc.ToString();
     SecurityElement se = new SecurityElement("");
     PolicyLevel pl = (PolicyLevel)Activator.CreateInstance(typeof(PolicyLevel), true);
     admc.FromXml(se);
     admc.FromXml(se, pl);
     se = admc.ToXml();
     se = admc.ToXml(pl);
 }
		public void Equals ()
		{
			ApplicationDirectoryMembershipCondition ad = new ApplicationDirectoryMembershipCondition ();
			Assert.IsFalse (ad.Equals (null), "Equals(null)");
			ApplicationDirectoryMembershipCondition g2 = new ApplicationDirectoryMembershipCondition ();
			Assert.IsTrue (ad.Equals (g2), "Equals(g2)");
			Assert.IsTrue (g2.Equals (ad), "Equals(ad)");
			Assert.IsFalse (ad.Equals (new object ()), "Equals (object)");
		}