Exemplo n.º 1
0
        /// <summary>
        /// Deserialises the Collection
        /// </summary>
        /// <param name="ASerialisedCollection"></param>
        public void DeserialiseCollection(string ASerialisedCollection)
        {
            string[] ColumnSettingArray = ASerialisedCollection.Split(new string[] { "&&" }, StringSplitOptions.None);

            foreach (string ColumnSetting in ColumnSettingArray)
            {
                TColumnSetting tcs = new TColumnSetting(ColumnSetting);
                SetSettingForColumn(tcs);
            }
        }
Exemplo n.º 2
0
 /// <summary>
 /// Sets the Column Settings for an existing or a new Column Name
 /// </summary>
 /// <param name="AColumnName"></param>
 /// <param name="AColumnSetting"></param>
 public void SetSettingForColumn(String AColumnName, TColumnSetting AColumnSetting)
 {
     if (FColumns.ContainsKey(AColumnName))
     {
         FColumns[AColumnName] = AColumnSetting;
     }
     else
     {
         FColumns.Add(AColumnName, AColumnSetting);
     }
 }
Exemplo n.º 3
0
 /// <summary>
 /// Sets the Column Settings for an existing or a new Column Name stored inside the AColumnSetting object.
 /// </summary>
 /// <param name="AColumnSetting"></param>
 public void SetSettingForColumn(TColumnSetting AColumnSetting)
 {
     if (FColumns.ContainsKey(AColumnSetting.ColumnName))
     {
         FColumns[AColumnSetting.FColumnName] = AColumnSetting;
     }
     else
     {
         if (AColumnSetting.FColumnName != String.Empty)
         {
             FColumns.Add(AColumnSetting.FColumnName, AColumnSetting);
         }
         else
         {
             throw new Exception(Catalog.GetString("TColumnSetting does not contain a name."));
         }
     }
 }