模型
public class ChartData
{
public IEnumerable<Series> Series { get; set; }
public string[] Categories { get; set; }
}
public class Series
{
// there is another types
}
我有两个数据作为ChartData
类型
// I debugged the following, data is like my expected.
chartData = HighchartsManager.GetBranchsMeterReadingsChartData();
chartDataCustomerAvg = HighchartsManager.GetCustomerAvgChartData();
我尝试连接这两个结构的系列,如下所示
// chartData.Series.Count > 3
// chartData.Series.Count > 2
// I want chartData.Series > 5 (3+2), after following line
chartData.Series.Concat(chartDataCustomerAvg.Series);
但是没有变过来chartData.Series
。如何添加IEnumerable
到另一个?