mirror of
https://github.com/emilybache/GildedRose-Refactoring-Kata.git
synced 2026-02-15 22:41:30 +00:00
Update Program.cs
This commit is contained in:
parent
e625aed95a
commit
f0946e11dd
@ -50,7 +50,15 @@ namespace GildedRoseKata
|
||||
foreach (Item t in items)
|
||||
{
|
||||
Console.WriteLine(t.Name + ", " + t.SellIn + ", " + t.Quality);
|
||||
|
||||
Type type = t.GetType();
|
||||
|
||||
object[] parametersArray = new object[] { "Hello" };
|
||||
|
||||
var singleMethod = type.GetMethods(BindingFlags.Public)
|
||||
.FirstOrDefault(m => m.Name == "UpdateQuality");
|
||||
|
||||
singleMethod.Invoke(type, parametersArray);
|
||||
|
||||
}
|
||||
|
||||
Console.WriteLine("");
|
||||
|
||||
Loading…
Reference in New Issue
Block a user