public SArray(Array array) { Values = new ISItem[array.Length]; for (var i = 0; i < array.Length; i++) { Values[i] = SConvert.ToSettings(array.GetValue(i)); } }
// Set the property value by index. public override bool TrySetIndex(SetIndexBinder binder, object[] indexes, object value) { if (typeof(long).IsAssignableFrom(indexes[0].GetType())) { Values[(long)indexes[0]] = SConvert.ToSettings(value); return(true); } return(false); }
public bool SetMember(string name, object value) { if (value == null && _properties.ContainsKey(name)) { _properties.Remove(name); } else { _properties[name] = SConvert.ToSettings(value); } return(true); }