示例#1
0
        public void Start()
        {
            CheckDisposed();

            if (Started)
            {
                return;
            }

            root.Start();
            description_server.Start();
            ssdp_server.Start();
            Started = true;
        }
示例#2
0
        public virtual void Start()
        {
            lock (mutex) {
                if (started)
                {
                    throw new InvalidOperationException("The server is already started.");
                }
                if (root_device == null)
                {
                    throw new ObjectDisposedException(ToString());
                }

                if (description_server == null)
                {
                    Initialize();
                }
                root_device.Start();
                description_server.Start();
                ssdp_server.Start();
                started = true;
            }
        }