想請問一個array封裝的辦法
Ex:
private Dictionary<string, string>[] xyz =
new Dictionary<string, string>[]
{
new Dictionary<string, string>(),
new Dictionary<string, string>(),
new Dictionary<strgin, string>()
}
public Dictionary<string, string>[] Xyz
{
get;
set;
}
請問get, set部分應該怎麼寫才能夠access到每個元素呢?
可能用法如下:
Dictionary<string, string> x1 = Xyz[0];
請各位不吝賜教, 謝謝