public bool Equals(YmnosGroup ymnosGroup) { if (ymnosGroup == null) { throw new ArgumentNullException("YmnosGroup.Equals"); } return(Ihos.Equals(ymnosGroup.Ihos) && Annotation == ymnosGroup.Annotation && Prosomoion == ymnosGroup.Prosomoion); //&& Annotation?.Equals(ymnosGroup.Annotation) == true //&& Prosomoion?.Equals(ymnosGroup.Prosomoion) == true); }
/// <summary> /// Возвращает группу с параметрами родителя и с одним песнопением по указанному индексу /// </summary> /// <param name="index"></param> /// <returns></returns> public YmnosGroup GetGroupWithSingleYmnos(int index) { if (index < 0 || index >= Ymnis.Count) { throw new IndexOutOfRangeException("GetGroupWithSingleYmnos"); } var result = new YmnosGroup(); result.CloneValues(this); result.Ymnis.Add(new Ymnos(Ymnis[index])); return(result); }
private void CloneValues(YmnosGroup source) { if (source.Prosomoion != null) { Prosomoion = new Prosomoion(source.Prosomoion); } if (source.Annotation != null) { Annotation = new ItemText(source.Annotation); } Ihos = source.Ihos; }
public YmnosStructure(YmnosStructure ymnosStructure) { if (ymnosStructure == null) { throw new ArgumentNullException("YmnosStructure"); } ymnosStructure.Groups.ForEach(c => Groups.Add(new YmnosGroup(c))); if (ymnosStructure.Doxastichon != null) { Doxastichon = new YmnosGroup(ymnosStructure.Doxastichon); } ymnosStructure.Theotokion.ForEach(c => Theotokion.Add(new YmnosGroup(c))); }
public YmnosGroup(YmnosGroup source) { CloneValues(source); source.Ymnis.ForEach(c => Ymnis.Add(new Ymnos(c))); }
public YmnosStructure(YmnosGroup group) { Groups.Add(new YmnosGroup(group)); }