public File Update(int valueId, int id, File value)
        {
            //Mimic DB exception thrown by no record found
            if (Files.All(x => x.ValueId == valueId && x.Id != id))
            {
                throw new NotFoundException();
            }

            var dbValue = Files.Find(x => x.ValueId == valueId && x.Id == id);

            dbValue.Stream = value.Stream;
            return(dbValue);
        }
 public File Add(int valueId, File value)
 {
     value.Id = Files.Max(x => x.Id) + 1;
     Files.Add(value);
     return(value);
 }