You can use a linq lambda for this.
column[] columns = getColumninfo();
columns.ToDictionary(x => x.name, y => y);
By adding StringComparer.OrdinalIgnoreCase
you can ensure that the column name lookup is case insensitive.
columns.ToDictionary(x => x.name, y => y, StringComparer.OrdinalIgnoreCase);
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…