/// <summary> /// Creates a new proxy object from the current implementation instance. A shortcut to <see cref="ProxyImplementationBinder.GetProxy"/> on the current instance. /// </summary> /// <returns>The new proxy.</returns> public TBound GetProxy() { return(ProxyImplementationBinder.GetProxy <TBound, TImplementation>((TImplementation)(object)this)); }
/// <summary> /// A shortcut to <see cref="ProxyImplementationBinder.GetImplementation"/>. /// </summary> /// <param name="proxy">The proxy for the class.</param> /// <returns>The implmentation of the proxy.</returns> public TImplementation GetImplementation(TBound proxy) { return(ProxyImplementationBinder.GetImplementation <TBound, TImplementation>(proxy)); }
/// <summary> /// A shortcut to <see cref="ProxyImplementationBinder.GetProxy"/>. /// </summary> /// <param name="impl">The custom implementation of the class.</param> /// <returns>The proxy for the class.</returns> protected TBound GetProxy(TImplementation impl) { return(ProxyImplementationBinder.GetProxy <TBound, TImplementation>(impl)); }