Intersect() public method

public Intersect ( IPermission target ) : IPermission
target IPermission
return IPermission
		public void Intersect ()
		{
			GacIdentityPermission gip = new GacIdentityPermission ();

			GacIdentityPermission intersect = (GacIdentityPermission)gip.Intersect (null);
			Assert.IsNull (intersect, "gip N null");

			GacIdentityPermission empty = new GacIdentityPermission (PermissionState.None);
			intersect = (GacIdentityPermission)gip.Intersect (empty);
			Assert.IsNotNull (intersect, "gip N null");

			intersect = (GacIdentityPermission)gip.Intersect (gip);
			Assert.IsNotNull (intersect, "gip N gip");
		}
		public void Intersect_DifferentPermissions ()
		{
			GacIdentityPermission a = new GacIdentityPermission (PermissionState.None);
			SecurityPermission b = new SecurityPermission (PermissionState.None);
			a.Intersect (b);
		}