websocket-sharp : WebSocketSharp.Net Namespace

# HttpListenerPrefixCollection Class

Provides the collection used to store the URI prefixes for the WebSocketSharp.Net.HttpListener.

## Syntax

public class HttpListenerPrefixCollection : ICollection<string>, IEnumerable<string>

## Remarks

Documentation for this section has not yet been entered.

## Requirements

Namespace: WebSocketSharp.Net
Assembly: websocket-sharp (in websocket-sharp.dll)

## Members

See Also: Inherited members from object.

## Public Properties

[read-only] | Count | int . Gets the number of prefixes contained in the WebSocketSharp.Net.HttpListenerPrefixCollection.
[read-only] | IsReadOnly | bool . Gets a value indicating whether access to the WebSocketSharp.Net.HttpListenerPrefixCollection is read-only.
[read-only] | IsSynchronized | bool . Gets a value indicating whether access to the WebSocketSharp.Net.HttpListenerPrefixCollection is synchronized.

## Public Methods

| Add (string) Adds the specified uriPrefix to the WebSocketSharp.Net.HttpListenerPrefixCollection.
| Clear () Removes all URI prefixes from the WebSocketSharp.Net.HttpListenerPrefixCollection.
| Contains (string) : bool Returns a value indicating whether the WebSocketSharp.Net.HttpListenerPrefixCollection contains the specified uriPrefix.
| CopyTo (Array, int) Copies the contents of the WebSocketSharp.Net.HttpListenerPrefixCollection to the specified Array.
| CopyTo (string[], int) Copies the contents of the WebSocketSharp.Net.HttpListenerPrefixCollection to the specified array of string.
| GetEnumerator () : IEnumerator<string> Gets an object that can be used to iterate through the WebSocketSharp.Net.HttpListenerPrefixCollection.
| Remove (string) : bool Removes the specified uriPrefix from the list of prefixes in the WebSocketSharp.Net.HttpListenerPrefixCollection.

## Explicitly Implemented Interface Members

| IEnumerable.GetEnumerator | Gets an object that can be used to iterate through the WebSocketSharp.Net.HttpListenerPrefixCollection.

## Extension Methods

static | IsNull<T> (this T) : bool Determines whether the specified object is `null`.
static | IsNullDo<T> (this T, Action) : bool Determines whether the specified object is `null`. And invokes the specified Action delegate if the specified object is `null`.

## Member Details

### Add Method

> Adds the specified uriPrefix to the WebSocketSharp.Net.HttpListenerPrefixCollection.

> ## Syntax

> public void Add (string uriPrefix)

> #### Parameters

> > uriPrefix
> >   A string that contains a URI prefix to add.

> #### Exceptions

> > Type | Reason
> > --- | ---
> > ArgumentNullException | uriPrefix is `null`.
> > ObjectDisposedException | The WebSocketSharp.Net.HttpListener associated with this WebSocketSharp.Net.HttpListenerPrefixCollection is closed.

> ## Remarks

> Documentation for this section has not yet been entered.

> ## Requirements

> Namespace: WebSocketSharp.Net
> Assembly: websocket-sharp (in websocket-sharp.dll)

### Clear Method

> Removes all URI prefixes from the WebSocketSharp.Net.HttpListenerPrefixCollection.

> ## Syntax

> public void Clear ()

> #### Exceptions

> > Type | Reason
> > --- | ---
> > ObjectDisposedException | The WebSocketSharp.Net.HttpListener associated with this WebSocketSharp.Net.HttpListenerPrefixCollection is closed.

> ## Remarks

> Documentation for this section has not yet been entered.

> ## Requirements

> Namespace: WebSocketSharp.Net
> Assembly: websocket-sharp (in websocket-sharp.dll)

### Contains Method

> Returns a value indicating whether the WebSocketSharp.Net.HttpListenerPrefixCollection contains the specified uriPrefix.

> ## Syntax

> public bool Contains (string uriPrefix)

> #### Parameters

> > uriPrefix
> >   A string that contains a URI prefix to test.

> #### Returns

> > `true` if the WebSocketSharp.Net.HttpListenerPrefixCollection contains the specified uriPrefix; otherwise, `false`.

> #### Exceptions

> > Type | Reason
> > --- | ---
> > ArgumentNullException | uriPrefix is `null`.
> > ObjectDisposedException | The WebSocketSharp.Net.HttpListener associated with this WebSocketSharp.Net.HttpListenerPrefixCollection is closed.

> ## Remarks

> Documentation for this section has not yet been entered.

> ## Requirements

> Namespace: WebSocketSharp.Net
> Assembly: websocket-sharp (in websocket-sharp.dll)

### CopyTo Method

> Copies the contents of the WebSocketSharp.Net.HttpListenerPrefixCollection to the specified Array.

> ## Syntax

> public void CopyTo (Array array, int offset)

> #### Parameters

> > array
> >   An Array that receives the URI prefix strings in the WebSocketSharp.Net.HttpListenerPrefixCollection.
> > offset
> >   An int that contains the zero-based index in array at which copying begins.

> #### Exceptions

> > Type | Reason
> > --- | ---
> > ObjectDisposedException | The WebSocketSharp.Net.HttpListener associated with this WebSocketSharp.Net.HttpListenerPrefixCollection is closed.

> ## Remarks

> Documentation for this section has not yet been entered.

> ## Requirements

> Namespace: WebSocketSharp.Net
> Assembly: websocket-sharp (in websocket-sharp.dll)

### CopyTo Method

> Copies the contents of the WebSocketSharp.Net.HttpListenerPrefixCollection to the specified array of string.

> ## Syntax

> public void CopyTo (string[] array, int offset)

> #### Parameters

> > array
> >   An array of string that receives the URI prefix strings in the WebSocketSharp.Net.HttpListenerPrefixCollection.
> > offset
> >   An int that contains the zero-based index in array at which copying begins.

> #### Exceptions

> > Type | Reason
> > --- | ---
> > ObjectDisposedException | The WebSocketSharp.Net.HttpListener associated with this WebSocketSharp.Net.HttpListenerPrefixCollection is closed.

> ## Remarks

> Documentation for this section has not yet been entered.

> ## Requirements

> Namespace: WebSocketSharp.Net
> Assembly: websocket-sharp (in websocket-sharp.dll)

### Count Property

> Gets the number of prefixes contained in the WebSocketSharp.Net.HttpListenerPrefixCollection.

> ## Syntax

> public int Count { get; }

> #### Value

> > A int that contains the number of prefixes.

> ## Remarks

> Documentation for this section has not yet been entered.

> ## Requirements

> Namespace: WebSocketSharp.Net
> Assembly: websocket-sharp (in websocket-sharp.dll)

### GetEnumerator Method

> Gets an object that can be used to iterate through the WebSocketSharp.Net.HttpListenerPrefixCollection.

> ## Syntax

> public IEnumerator<string> GetEnumerator ()

> #### Returns

> > An object that implements the IEnumerator<string> interface and provides access to the URI prefix strings in the WebSocketSharp.Net.HttpListenerPrefixCollection.

> ## Remarks

> Documentation for this section has not yet been entered.

> ## Requirements

> Namespace: WebSocketSharp.Net
> Assembly: websocket-sharp (in websocket-sharp.dll)

### IsReadOnly Property

> Gets a value indicating whether access to the WebSocketSharp.Net.HttpListenerPrefixCollection is read-only.

> ## Syntax

> public bool IsReadOnly { get; }

> #### Value

> > Always returns `false`.

> ## Remarks

> Documentation for this section has not yet been entered.

> ## Requirements

> Namespace: WebSocketSharp.Net
> Assembly: websocket-sharp (in websocket-sharp.dll)

### IsSynchronized Property

> Gets a value indicating whether access to the WebSocketSharp.Net.HttpListenerPrefixCollection is synchronized.

> ## Syntax

> public bool IsSynchronized { get; }

> #### Value

> > Always returns `false`.

> ## Remarks

> Documentation for this section has not yet been entered.

> ## Requirements

> Namespace: WebSocketSharp.Net
> Assembly: websocket-sharp (in websocket-sharp.dll)

### Remove Method

> Removes the specified uriPrefix from the list of prefixes in the WebSocketSharp.Net.HttpListenerPrefixCollection.

> ## Syntax

> public bool Remove (string uriPrefix)

> #### Parameters

> > uriPrefix
> >   A string that contains a URI prefix to remove.

> #### Returns

> > `true` if the uriPrefix was found in the WebSocketSharp.Net.HttpListenerPrefixCollection and removed; otherwise, `false`.

> #### Exceptions

> > Type | Reason
> > --- | ---
> > ArgumentNullException | uriPrefix is `null`.
> > ObjectDisposedException | The WebSocketSharp.Net.HttpListener associated with this WebSocketSharp.Net.HttpListenerPrefixCollection is closed.

> ## Remarks

> Documentation for this section has not yet been entered.

> ## Requirements

> Namespace: WebSocketSharp.Net
> Assembly: websocket-sharp (in websocket-sharp.dll)

### System.Collections.IEnumerable.GetEnumerator Method

> Gets an object that can be used to iterate through the WebSocketSharp.Net.HttpListenerPrefixCollection.

> ## Syntax

> IEnumerator System.Collections.IEnumerable.GetEnumerator ()

> #### Returns

> > An object that implements the IEnumerator interface and provides access to the URI prefix strings in the WebSocketSharp.Net.HttpListenerPrefixCollection.

> ## Remarks

> Documentation for this section has not yet been entered.

> ## Requirements

> Namespace: WebSocketSharp.Net
> Assembly: websocket-sharp (in websocket-sharp.dll)