protected void DataToControls()
{
CrossPointSwitch crossPointSwitch = _item as CrossPointSwitch;
if (crossPointSwitch != null)
{
edtLineCount.Value = crossPointSwitch.lineCount;
if (crossPointSwitch.Columns != null)
{
lvColumns.Items.Clear();
foreach (SwitchPort port in crossPointSwitch.Columns)
{
AddListViewItem(port, lvColumns);
}
}
if (crossPointSwitch.Rows != null)
{
lvRows.Items.Clear();
foreach (SwitchPort port in crossPointSwitch.Rows)
{
AddListViewItem(port, lvRows);
}
}
}
}