VerifyChar() public méthode

Tests whether the specified character would be set successfully at the specified position.
public VerifyChar ( char input, int position, MaskedTextResultHint &hint ) : bool
input char
position int
hint MaskedTextResultHint
Résultat bool
		public void VerifyCharTest00001 ()
		{
			MaskedTextProvider mtp;
			int Int32_out = 0;
			MaskedTextResultHint MaskedTextResultHint_out = MaskedTextResultHint.Unknown;
			mtp = new MaskedTextProvider (@"abc");
			mtp.Add (@"a");
			mtp.Add ('\x61');
			mtp.Add ('\x61', out Int32_out, out MaskedTextResultHint_out);
			Assert.AreEqual (false, mtp.VerifyChar ('\x0', -1, out MaskedTextResultHint_out), "#0");
			Assert.AreEqual (MaskedTextResultHint.PositionOutOfRange, MaskedTextResultHint_out, "#1");
			MaskedTextProviderTest.AssertProperties (mtp, "VerifyCharTest", 2, true, false, 1, 0, CultureInfo.GetCultureInfo ("es-ES"), 1, true, false, false, 0, 3, @"abc", true, true, '\x0', '\x5F', true, true, true, @"abc", @"abc", @"abc", @"abc", @"a", @"abc", @"a");
		}
		public void VerifyCharTest00064 ()
		{
			MaskedTextProvider mtp;
			int Int32_out = 0;
			MaskedTextResultHint MaskedTextResultHint_out = MaskedTextResultHint.Unknown;
			mtp = new MaskedTextProvider (@"abc");
			mtp.Add (@"a");
			mtp.Add ('\x61');
			mtp.Add ('\x61', out Int32_out, out MaskedTextResultHint_out);
			Assert.AreEqual (true, mtp.VerifyChar ('\x20', 0, out MaskedTextResultHint_out), "#138");
			Assert.AreEqual (MaskedTextResultHint.SideEffect, MaskedTextResultHint_out, "#139");
			MaskedTextProviderTest.AssertProperties (mtp, "VerifyCharTest", 140, true, false, 1, 0, CultureInfo.GetCultureInfo ("es-ES"), 1, true, false, false, 0, 3, @"abc", true, true, '\x0', '\x5F', true, true, true, @"abc", @"abc", @"abc", @"abc", @"a", @"abc", @"a");
		}
		public void VerifyCharTest01186 ()
		{
			MaskedTextProvider mtp;
			int Int32_out = 0;
			MaskedTextResultHint MaskedTextResultHint_out = MaskedTextResultHint.Unknown;
			mtp = new MaskedTextProvider (@"09#L?&CAa.,:/$<>|\\");
			mtp.Add (@"a");
			mtp.Add ('\x61');
			mtp.Add ('\x61', out Int32_out, out MaskedTextResultHint_out);
			Assert.AreEqual (true, mtp.VerifyChar ('\x2F', 12, out MaskedTextResultHint_out), "#0");
			Assert.AreEqual (MaskedTextResultHint.CharacterEscaped, MaskedTextResultHint_out, "#1");
			MaskedTextProviderTest.AssertProperties (mtp, "VerifyCharTest", 2, true, false, 0, 9, CultureInfo.GetCultureInfo ("es-ES"), 9, true, false, false, -1, 15, @"09#L?&CAa.,:/$<>|\\", false, false, '\x0', '\x5F', true, true, true, @"         ,.:/€\", @"         ,.:/€\", @"         ,.:/€\", @"_________,.:/€\", @"_________", @"         ,.:/€\", @"");
		}