/// <summary> /// Instantiate proxy object for a given resource type name /// </summary> private ResourceProxy InstantiateProxy(string typeName, Resource instance) { var proxyType = ProxyBuilder.GetType(_proxyTypeCache[typeName]); var proxyInstance = (ResourceProxy)Activator.CreateInstance(proxyType, instance, this); proxyInstance.Attach(); return(proxyInstance); }