Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
10/04/19 14:23:08 (5 years ago)
Author:
abeham
Message:

#2521: reverted r17309

Location:
branches/2521_ProblemRefactoring/HeuristicLab.Data/3.3
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • branches/2521_ProblemRefactoring/HeuristicLab.Data/3.3/BoolArray.cs

    r17309 r17315  
    2020#endregion
    2121
    22 using System.Collections.Generic;
    2322using System.Text;
    2423using HEAL.Attic;
     
    3837    public BoolArray(int length) : base(length) { }
    3938    public BoolArray(bool[] elements, bool @readonly = false) : base(elements, @readonly) { }
    40     public BoolArray(IReadOnlyList<bool> elements) : base(elements) { }
    4139
    4240    public override IDeepCloneable Clone(Cloner cloner) {
  • branches/2521_ProblemRefactoring/HeuristicLab.Data/3.3/StringConvertibleArray.cs

    r17309 r17315  
    2222#endregion
    2323
    24 using System.Collections.Generic;
    2524using HEAL.Attic;
    2625using HeuristicLab.Common;
     
    3938    protected StringConvertibleArray(int length) : base(length) { }
    4039    protected StringConvertibleArray(T[] elements, bool @readonly = false) : base(elements, @readonly) { }
    41     protected StringConvertibleArray(IReadOnlyList<T> elements) : base(elements) { }
    4240
    4341    protected abstract bool Validate(string value, out string errorMessage);
  • branches/2521_ProblemRefactoring/HeuristicLab.Data/3.3/ValueTypeArray.cs

    r17309 r17315  
    138138    }
    139139    protected ValueTypeArray(T[] elements, bool @readonly = false) {
    140       if (elements == null) throw new ArgumentNullException(nameof(elements));
     140      if (elements == null) throw new ArgumentNullException();
    141141      array = (T[])elements.Clone();
    142142      readOnly = @readonly;
    143143      resizable = true;
    144144      elementNames = new List<string>();
    145     }
    146    
    147     protected ValueTypeArray(IReadOnlyList<T> elements) {
    148       if (elements == null) throw new ArgumentNullException(nameof(elements));
    149       array = elements.ToArray(); // TODO: array should be an IList<T>
    150       readOnly = true;
    151       resizable = true; // TODO: really?
    152       elementNames = new List<string>(); // TODO: wasteful
    153145    }
    154146
Note: See TracChangeset for help on using the changeset viewer.