本文整理汇总了C#中ColumnDefinition.Property方法的典型用法代码示例。如果您正苦于以下问题:C# ColumnDefinition.Property方法的具体用法?C# ColumnDefinition.Property怎么用?C# ColumnDefinition.Property使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类ColumnDefinition
的用法示例。
在下文中一共展示了ColumnDefinition.Property方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: will_not_write_a_null_property_because_that_wigs_out_at_runtime
public void will_not_write_a_null_property_because_that_wigs_out_at_runtime()
{
var column = new ColumnDefinition<ColumnDefTarget, string>(x => x.Name, theProjection);
column.Property("something", null);
// just wanna see it not blow up
writeColumn(column);
}
示例2: alteration_delegates
public void alteration_delegates()
{
var column = new ColumnDefinition<GridDefinition_selecting_editors_specs.GridDefTarget, String>(
x => x.Name, new Projection<GridDefinition_selecting_editors_specs.GridDefTarget>());
var rule = new LambdaColumnRule(a => a.PropertyType == typeof(string),
c => c.Properties["foo"] = "bar");
rule.Alter(column);
column.Property("foo").ShouldEqual("bar");
}
示例3: apply_any_rules
public void apply_any_rules()
{
var column = new ColumnDefinition<ColumnDefTarget, string>(x => x.Name, theProjection);
var column2 = new ColumnDefinition<ColumnDefTarget, bool>(x => x.IsCool, theProjection);
var grid = MockRepository.GenerateMock<IGridDefinition>();
var policies = new ColumnPolicies();
policies.If(a => a.Name == "Name").SetProperty("foo", 1).SetProperty("bar", 2);
column.SelectFormatterAndEditor(grid, policies);
column.Property("foo", 1);
column.Property("bar", 2);
column2.SelectFormatterAndEditor(grid, policies);
column2.Property("foo").ShouldBeNull();
column2.Property("bar").ShouldBeNull();
}