You've already forked taptap2024_GJ_chidouren
32 lines
780 B
C#
32 lines
780 B
C#
using System.Collections.Generic;
|
|
|
|
namespace IcecreamView
|
|
{
|
|
public class EventArg
|
|
{
|
|
|
|
private List<object> values;
|
|
|
|
public EventArg(params object[] values)
|
|
{
|
|
if (values == null)
|
|
{
|
|
this.values = null;
|
|
return;
|
|
}
|
|
this.values = new List<object>(values);
|
|
}
|
|
|
|
public T GetValue<T>(int index = 0)
|
|
{
|
|
if (this.values == null || index >= this.values.Count)
|
|
{
|
|
return default;
|
|
}
|
|
return (T)this.values[index];
|
|
}
|
|
public bool IsNotNull(int index = 0) { return this.values.Count > index && this.values[index] != null; }
|
|
|
|
public int Count => values.Count;
|
|
}
|
|
} |