我有一个事件定义如下:
public interface IClass
{
DateTime EffectiveDate { get; set; }
IChild[] Children { get; set; }
}
public interface IChild
{
string From { get; set; }
string To { get; set; }
decimal ADecimal { get; set; }
}
我正在尝试使用以下语法
bus.send<IClass>(class=>
{
class.EffeciveDate = DateTime.now;
class.Children = //Not sure what to do here
}
如何实例化数组并填充子对象?