当前位置: 首页>>代码示例>>C#>>正文


C# Poker.SaveState方法代码示例

本文整理汇总了C#中Poker.SaveState方法的典型用法代码示例。如果您正苦于以下问题:C# Poker.SaveState方法的具体用法?C# Poker.SaveState怎么用?C# Poker.SaveState使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Poker的用法示例。


在下文中一共展示了Poker.SaveState方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: Label_ViewState

		public void Label_ViewState ()
		{
			Poker p = new Poker ();
			p.TrackState ();

			Assert.AreEqual (p.Text, "", "A1");
			p.Text = "Hello";
			Assert.AreEqual (p.Text, "Hello", "A2");

			object state = p.SaveState ();

			Poker copy = new Poker ();
			copy.TrackState ();
			copy.LoadState (state);
			Assert.AreEqual (copy.Text, "Hello", "A3");
		}
开发者ID:nobled,项目名称:mono,代码行数:16,代码来源:LabelTest.cs

示例2: FormView_ViewState

		public void FormView_ViewState ()
		{
			Poker fv = new Poker ();
			Poker copy = new Poker ();
			fv.AllowPaging = true;
			fv.HeaderText = "Testing";
			fv.CssClass = "style.css";
			object state = fv.SaveState ();
			copy.LoadState (state);
			Assert.AreEqual (true, copy.AllowPaging, "ViewStateAllowPaging");
			Assert.AreEqual ("Testing", copy.HeaderText, "ViewStateHeaderText");
			Assert.AreEqual ("style.css", copy.CssClass, "ViewStateCssClass");
		}
开发者ID:JokerMisfits,项目名称:linux-packaging-mono,代码行数:13,代码来源:FormViewTest.cs

示例3: ViewState

		public void ViewState ()
		{
			Poker p = new Poker ();
			Poker copy = new Poker ();

			p.DataSourceID = "hi";
			object state = p.SaveState ();
			copy.LoadState (state);

			Assert.AreEqual ("hi", copy.DataSourceID, "A1");
		}
开发者ID:Profit0004,项目名称:mono,代码行数:11,代码来源:BaseDataBoundControlTest.cs

示例4: ViewState

		public void ViewState ()
		{
			Poker t = new Poker ();

			t.TrackState();

			t.ValidationGroup = "VG";
			t.CausesValidation = true;

			object s = t.SaveState ();
			Console.WriteLine ("state = {0}", s == null ? "null" : "not-null");

			Poker copy = new Poker ();

			copy.LoadState (s);

			Assert.AreEqual ("VG", copy.ValidationGroup, "A1");
			Assert.IsTrue (copy.CausesValidation, "A2");
		}
开发者ID:calumjiao,项目名称:Mono-Class-Libraries,代码行数:19,代码来源:TextBoxTest.cs

示例5: TestValidationGroup

		public void TestValidationGroup ()
		{
			Poker p = new Poker ();
			p.TrackState ();

			Assert.AreEqual (p.ValidationGroup, "", "V1");
			p.ValidationGroup = "VG1";
			Assert.AreEqual (p.ValidationGroup, "VG1", "V2");

			object state = p.SaveState ();

			Poker copy = new Poker ();
			copy.TrackState ();
			copy.LoadState (state);
			Assert.AreEqual (copy.ValidationGroup, "VG1", "A3");
		}
开发者ID:nobled,项目名称:mono,代码行数:16,代码来源:LinkButtonTest.cs


注:本文中的Poker.SaveState方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。