sdfgrtyu 2015-01-22 12:39 采纳率: 0%
浏览 1471

asp.net求助????????,求解答

public virtual object DataSource
{
[TargetedPatchingOptOut("Performance critical to inline this type of method across NGen image boundaries")]
get
{
return this.dataSource;
}
set
{
if (((value != null) && !(value is IListSource)) && !(value is IEnumerable))
{
throw new ArgumentException(SR.GetString("Invalid_DataSource_Type", new object[] { this.ID }));
}
this.dataSource = value;
this.OnDataPropertyChanged();
}
}
上面这段代码什么意思?谁能给我解释一下?

  • 写回答

1条回答 默认 最新

  • threenewbee 2015-01-22 12:45
    关注

    就是定义了一个 DataSource的属性,并且在它更改的时候触发OnDataPropertyChanged事件。

    评论

报告相同问题?