1

I want to be able to do this.

MyInterface interface = new ServiceProxyHelper<ProxyType>(); 

Here's the object structure

MyTypeThatImplementsMyInterface : MyInterface 

Will this work?

public class ProxyType : MyInterface {} public class ServiceProxyHelper<ProxyType> : IDisposable, MyInterface {} 
1

1 Answer 1

3

I think this is what you're trying to do:

public class ServiceProxyHelper<T> where T : MyInterface { ... } 
Sign up to request clarification or add additional context in comments.

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.