It sounds like you want to dispatch to the 'correct' method based on the actual generic type, like so:
public int GenericMethod<T>(T t)
{
if (t is int)
{
return method1(t as int);
}
else if (t is bool)
{
return method2(t as bool);
}
else if (t is float)
{
return method3(t as float);
}
...
throw new ArgumentInvalidException(...);
}
However, if the goal is to provide a "single method" that can be used polymorphically across a limited range of types, then I question why a generic is necessary. You can use method overloading and get exactly the same developer experience, like so:
public int method(int arg)
{
return method1(arg);
}
public int method(bool arg)
{
return method2(arg);
}
public int method(float arg)
{
return method3(arg);
}