I have a generic method
bool DoesEntityExist<T>(Guid guid, ITransaction transaction) where T : IGloballyIdentifiable;
How do I use the method in the following way:
Type t = entity.GetType();
DoesEntityExist<t>(entityGuid, transaction);
I keep receiving the foollowing compile error:
The type or namespace name 't' could not be found (are you missing a using directive or an assembly reference?)
DoesEntityExist<MyType>(entityGuid, transaction);
works perfectly but I do not want to use an if directive to call the method with a separate type name every time.