定义为List[ ] 数组,会不会有什么隐患 ?
puler 2014-09-27 10:25:09 因为需要ABCD共计4组的数据,每组若干个数据List,
有谁这么用过,是否有啥隐患
public class Test_CanDel
{
public Test_CanDel()
{
List<TorrX>[] AAA = new List<TorrX>[4];
AAA[0] = new List<TorrX>();
AAA[0].Add(new TorrX
{
str_Torr_Loc = "12",
str_Torr_Way = "00",
str_Torr_How = "77",
torr_ShowCount = 55,
torr_distance_of_lastTorrShow = 78,
torr_ShowStr = "000111000111000111000111"
});
AAA[0].Add(new TorrX
{
str_Torr_Loc = "12",
str_Torr_Way = "00",
str_Torr_How = "77",
torr_ShowCount = 55,
torr_distance_of_lastTorrShow = 78,
torr_ShowStr = "000111000111000111000111"
});
Console.WriteLine("wait");
}//<--结束构造函数
}//<--结束类
public class TorrX
{
public string str_Torr_Loc { get; set; }
public string str_Torr_Way { get; set; }
public string str_Torr_How { get; set; }
public int torr_ShowCount { get; set; }//出现次数
public string torr_ShowStr { get; set; }//分布字符串
public int torr_distance_of_lastTorrShow { get; set; }//最后出现,距离尾巴多远
public int torr_ZGetPoint { get; set; }//得分
}//<-- 结束类 class TorrX