public class BaseClass{
public static T Find<T>(object value){
-- db.get<T>("params", value);
}
}
public class Derived: BaseClass{
}
...
void someMethod(){
Derived obj = Derived.Find<Derived>(1);
}
In the above code how do I change Derived obj = Derived.FindDerived<Derived>(1); to Derived obj = Derived.Find(1);
If your method signature were something like this
Then you could omit the type in the method call. However, from your given signature, the compiler is unable to infer the type without you stating it explicitly.