Here’s a piece of code in C# that I am trying to understand.
A class has the following method available in an interface.
T GetLookupValue<T, S>(string sTName, string sFName, string sLuName, S value);
When I use dotPeek to look at the usage of this class, it shows this.
public T GetLookupValue<T, S>(string sTName, string sFName, string sLuName, S value)
{
return (T) this.db.a(sTName, sFName, sLuName, false, (object) value, false, false);
}
How do I call this method? What do I need to substitute T and S with?
This method presents itself as a generalized lookup function. If the implementation can really handle any type, then you can use any type at all for S and T.
Examples: