110,534
社区成员
发帖
与我相关
我的任务
分享
[Serializable]
public class Model
{
Dictionary<string,int> dic;
List<string> lst;
public Model()
{
dic = new Dictionary<string,int>();
lst = new List<string>();
dic.Add("1",1);
lst.Add("2");
}
[OnDeserialized]
void OnDeser(StreamingContext sc)
{
//在这里dic的count为空,list的数量是有的
}
}