public List<StreamIdentifier> Insert(int index, CommandInput resource) { if (resource == null) { throw new ArgumentNullException("resource"); } resource.Owner = Owner; if (Owner.Objects.ContainsInput(resource)) { throw new ArgumentException("Command already contains the specified resource.", "resource"); } Owner.Objects.Inputs.Insert(index, resource); return resource.GetStreamIdentifiers(); }
public List <StreamIdentifier> Add(CommandInput resource) { if (resource == null) { throw new ArgumentNullException("resource"); } resource.Owner = Owner; if (Owner.Objects.ContainsInput(resource)) { throw new ArgumentException("Command already contains the specified resource.", "resource"); } Owner.Objects.Inputs.Add(resource); return(resource.GetStreamIdentifiers()); }