void DeepClone(IDeepClonable other) { // just to be sure .... if (other is ClassA) { var o = (ClassA)other; this.A = o.A; } }
/// <summary> /// Add or modify a specific gene in the extension. /// </summary> /// <param name="tag">Name of the gene</param> /// <param name="data">Data associated</param> public void setGeneticData(string tag, IDeepClonable data) { geneticData.set(tag, data); }
/// <summary> /// Add or modify a specific gene in the extension. /// </summary> /// <param name="tag">Name of the gene</param> /// <param name="data">Data associated</param> public void SetGeneticData(string tag, IDeepClonable data) { GeneticData.Set(tag, data); }
/// <summary> /// Add or modifiy a gene. /// </summary> /// <param name="element">The name of the gene</param> /// <param name="data">The value of the gene</param> public void Set(String element, IDeepClonable data) { this.data[element] = data; }
public Gene(Gene other) { this.Value = other.Value.Clone() as IDeepClonable <object>; }
public Gene(IDeepClonable <object> value) { this.Value = value; }