System.Net.EndPointListener.AddSpecial C# (CSharp) Метод

AddSpecial() приватный Метод

private AddSpecial ( ArrayList coll, System.Net.ListenerPrefix prefix ) : void
coll System.Collections.ArrayList
prefix System.Net.ListenerPrefix
Результат void
		void AddSpecial (ArrayList coll, ListenerPrefix prefix)
		{
			if (coll == null)
				return;

			try {
				plock.AcquireReaderLock (-1);
				foreach (ListenerPrefix p in coll) {
					if (p.Path == prefix.Path) //TODO: code
						throw new HttpListenerException (400, "Prefix already in use.");
				}
				plock.UpgradeToWriterLock (-1);
				coll.Add (prefix);
			} finally {
				try {
					plock.ReleaseReaderLock (); // This releases the writer lock if held.
				} catch { }
			}
		}