<generic> return type?
-
Hello, is it possible to return a generic type from a method in C#? Something like: public GetData() { T myReturnData; // // Code to fetch the data goes here.. // return myReturnData; } Obviously, this example doesn't compile, but is there a way to accomplish this? Thanks, Michal
-
Hello, is it possible to return a generic type from a method in C#? Something like: public GetData() { T myReturnData; // // Code to fetch the data goes here.. // return myReturnData; } Obviously, this example doesn't compile, but is there a way to accomplish this? Thanks, Michal
private T GetObject<T>(T t) { return t; }
only two letters away from being an asset
-
private T GetObject<T>(T t) { return t; }
only two letters away from being an asset
Great, thank you very much. Michal