I have
public static void SecureTcpRpc<InterfaceType>(string uri,
Action<InterfaceType> action)
where InterfaceType : class;
Then I use that here
private static AuthorizedActionResult
RunChannelAction<T>(IEnumerable<string> uris,
Func<T, AuthorizedActionResult> actionFunc)
where T : IPingable
{
WcfClient.SecureTcpRpc<T>....
THe compiler does not like that I have constrained T to be IPingable. I dont see why it objects. IPingable is a reference type, so it matches the constraint on the SecureTpcRpc method. But the compiler says ‘T must be a reference type’
I think you need the “class” constraint on the
AuthorizedActionResultfunction also for it to work.