// Create an instance of ServicedComponentProxy
        public override MarshalByRefObject CreateInstance(Type serverType)
        {
            mIsServiceComponent = serverType.IsSubclassOf(typeof(ServicedComponent));

            MarshalByRefObject lTarget = null;
            if (mIsServiceComponent)
                lTarget = mBase.CreateInstance(serverType);
            else
                lTarget = base.CreateInstance(serverType);
            RealProxy lRealProxy = new ONRealProxy(lTarget, serverType);

            return lRealProxy.GetTransparentProxy() as MarshalByRefObject;
        }
Beispiel #2
0
        // Create an instance of ServicedComponentProxy
        public override MarshalByRefObject CreateInstance(Type serverType)
        {
            mIsServiceComponent = serverType.IsSubclassOf(typeof(ServicedComponent));

            MarshalByRefObject lTarget = null;

            if (mIsServiceComponent)
            {
                lTarget = mBase.CreateInstance(serverType);
            }
            else
            {
                lTarget = base.CreateInstance(serverType);
            }
            RealProxy lRealProxy = new ONRealProxy(lTarget, serverType);

            return(lRealProxy.GetTransparentProxy() as MarshalByRefObject);
        }