E
Enosh Chang
Hi all:
I have one question about generic class.
public class Base<T>
where T : new()
{
public Base() {}
public void A()
{
T newObject = new T(parameter);
}
}
Document said I couldn't use T(parameter) but T(). Or do I have another way to do that? Thanks.
I have one question about generic class.
public class Base<T>
where T : new()
{
public Base() {}
public void A()
{
T newObject = new T(parameter);
}
}
Document said I couldn't use T(parameter) but T(). Or do I have another way to do that? Thanks.