/* public void AppendNamed(string AName, object P = NULL); * public bool DeleteNamed(AnsiString AName);*/ public void AppendInteger(int APos, object AValue) { int m = -1; TDynamicArrayItem Item; if (f_List.Count > 0) { m = ((TDynamicArrayItem)f_List.ElementAt(0)).Index; } for (int i = 1; i <= f_List.Count - 1; i++) { Item = (TDynamicArrayItem)(f_List.ElementAt(i)); if (Item.Index > m) { m = Item.Index; } } m++; Item = new TDynamicArrayItem(); Item.Index = m; Item.P = AValue; Item.Int_Value = APos; f_List.Add(Item); f_PosStak++; }
public TBaseShape GetTFE(int AIndex) { TDynamicArrayItem P = f_List.GetPosition(AIndex); if (P != null) { return((TBaseShape)(P.P)); } else { return(null); } }
public int GetTFE_ID(int AIndex) { TDynamicArrayItem P = f_List.GetPosition(AIndex); if (P != null) { return(P.Int_Value); } else { return(0); } }
public object GetItems(int AIndex) { TDynamicArrayItem Item = null; if (AIndex >= 0 && AIndex <= f_List.Count - 1) { Item = (TDynamicArrayItem)f_List.ElementAt(AIndex); } if (Item != null) { return(Item.P); } return(null); }
object GetArray(int AIndex) { TDynamicArrayItem Item, FindItem = null; for (int i = 0; i <= f_List.Count - 1; i++) { Item = (TDynamicArrayItem)f_List.ElementAt(i); if (Item.Index == AIndex) { FindItem = Item; } } if (FindItem != null) { return(FindItem.P); } return(null); }
void SetArray(int AIndex, object AValue) { TDynamicArrayItem Item, FindItem = null; for (int i = 0; i <= f_List.Count - 1; i++) { Item = (TDynamicArrayItem)f_List.ElementAt(i); if (Item.Index == AIndex) { FindItem = Item; } } if (FindItem == null) { FindItem = new TDynamicArrayItem(); FindItem.Index = AIndex; f_List.Add(FindItem); } FindItem.P = AValue; }
public void InsertToFirst(object P) { int m = -1; TDynamicArrayItem Item; if (f_List.Count > 0) { m = ((TDynamicArrayItem)f_List.ElementAt(0)).Index; } for (int i = 1; i <= f_List.Count - 1; i++) { Item = (TDynamicArrayItem)f_List.ElementAt(i); if (Item.Index > m) { m = Item.Index; } } m++; Item = new TDynamicArrayItem(); Item.Index = m; Item.P = P; f_List.Insert(0, Item); f_PosStak++; }