コード例 #1
0
 internal InstanceContext(ServiceHostBase host, bool isUserCreated)
 {
     _host         = host ?? throw DiagnosticUtility.ExceptionUtility.ThrowHelperArgumentNull(nameof(host));
     AutoClose     = true;
     _channels     = new ServiceChannelManager(this, NotifyEmptyCallback);
     IsUserCreated = isUserCreated;
 }
コード例 #2
0
            public ChannelCollection(ServiceChannelManager channelManager, object syncRoot)
            {
                if (syncRoot == null)
                {
                    throw DiagnosticUtility.ExceptionUtility.ThrowHelperArgumentNull(nameof(syncRoot));
                }

                this.channelManager = channelManager;
                this.syncRoot       = syncRoot;
            }
コード例 #3
0
 internal InstanceContext(ServiceHostBase host, object implementation, bool wellKnown, bool isUserCreated)
 {
     _host = host;
     if (implementation != null)
     {
         _userObject = implementation;
         IsWellKnown = wellKnown;
     }
     AutoClose     = false;
     _channels     = new ServiceChannelManager(this);
     IsUserCreated = isUserCreated;
 }
コード例 #4
0
ファイル: InstanceContext.cs プロジェクト: zheng1748/CoreWCF
        internal InstanceContext(ServiceHostBase host, bool isUserCreated)
        {
            // TODO: Why is it required that host != null?
            //if (host == null)
            //{
            //    throw DiagnosticUtility.ExceptionUtility.ThrowHelperArgumentNull(nameof(host));
            //}

            _host          = host;
            _autoClose     = true;
            _channels      = new ServiceChannelManager(this, NotifyEmptyCallback);
            _isUserCreated = isUserCreated;
        }
コード例 #5
0
 public ChannelCollection(ServiceChannelManager channelManager, object syncRoot)
 {
     _channelManager = channelManager;
     _syncRoot       = syncRoot ?? throw DiagnosticUtility.ExceptionUtility.ThrowHelperArgumentNull(nameof(syncRoot));
 }