public override void ReadJSON(JObject JObject, Dictionary <Int32, Int32> NodeMap, Dictionary <Int32, Int32> NodeTypeMap) { CswCommaDelimitedString NewSelectedNodeTypeIds = SelectedNodeTypeIds; CswCheckBoxArrayOptions CBAOptions = new CswCheckBoxArrayOptions(); if (null != JObject[_ElemName_Options]) { CBAOptions.ReadJson((JObject)JObject[_ElemName_Options]); } foreach (CswCheckBoxArrayOptions.Option Option in CBAOptions.Options) { if (Option.Values.Count > 0) { if (Option.Values.Count > 0 && true == Option.Values[0]) { NewSelectedNodeTypeIds.Add(Option.Key); } else if (false == Option.Values[0]) { NewSelectedNodeTypeIds.Remove(Option.Key); } } } SelectedNodeTypeIds = NewSelectedNodeTypeIds; } // ReadJSON()
} // ToJSON() public override void ReadJSON(JObject JObject, Dictionary <Int32, Int32> NodeMap, Dictionary <Int32, Int32> NodeTypeMap) { CswCheckBoxArrayOptions CBAOptions = new CswCheckBoxArrayOptions(); if (null != JObject[_ElemName_LogicalSetJson]) { CBAOptions.ReadJson((JObject)JObject[_ElemName_LogicalSetJson]); } foreach (CswCheckBoxArrayOptions.Option Option in CBAOptions.Options) { for (Int32 i = 0; i < Option.Values.Count; i++) { //TODO: this hasn't worked in a LOOOOOOONG Time. Case 29477. SetValue(CBAOptions.Columns[i], Option.Label, Option.Values[i]); } } Save(); } // ReadJSON()