индексатор
This commit is contained in:
parent
4da3dba800
commit
4d35cc62f5
@ -24,6 +24,10 @@
|
|||||||
/// Набор объектов
|
/// Набор объектов
|
||||||
/// </summary>
|
/// </summary>
|
||||||
private readonly SetLocomotivesGeneric<T> _setLocomotives;
|
private readonly SetLocomotivesGeneric<T> _setLocomotives;
|
||||||
|
public T GetObject(int index)
|
||||||
|
{
|
||||||
|
return _setLocomotives[index];
|
||||||
|
}
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Карта
|
/// Карта
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
@ -68,6 +68,19 @@
|
|||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
public IDrawningObject this[string dictIndex, int objIndex]
|
||||||
|
{
|
||||||
|
get
|
||||||
|
{
|
||||||
|
if (_mapStorages.ContainsKey(dictIndex))
|
||||||
|
{
|
||||||
|
var selectedDictElement = _mapStorages[dictIndex];
|
||||||
|
var selectedObject = selectedDictElement.GetObject(objIndex);
|
||||||
|
return selectedObject;
|
||||||
|
}
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user