public DependentConstructorKindArgument(ConstructorKind argument, IEnumerable <int> dependencies) { if (argument == null) { throw new ArgumentNullException(nameof(argument)); } this.Argument = argument; this.Dependencies = dependencies?.ToList().AsReadOnly(); if (this.Dependencies.Count == 0) { throw new ArgumentException("must have dependencies"); } if (!IsSorted(this.Dependencies)) { throw new ArgumentException("dependencies must be sorted"); } if (Argument.Arguments.Count <= Dependencies.Count) { throw new ArgumentException("invalid constructor"); } if (!AllUsed(Argument, Dependencies.Count)) { throw new ArgumentException("invalid constructor"); } }
private bool AllUsed(ConstructorKind argument, int count) { throw new NotImplementedException(); }