Pass Interface into function for use with Create<T>
I have this code :
var proxy = XmlRpcProxyGen.Create<IMessageRpc>();
var proxy2 = XmlRpcProxyGen.Create<ITestRpc>();
Create prototype is XmlRpcProxyGen.Create<T>
I would like use a function like this :
public object GetProxy(XXX)
{
return mlRpc开发者_开发问答ProxyGen.Create<XXX>();
}
public object GetProxy<T>()
{
return XmlRpcProxyGen.Create<T>();
}
精彩评论