Table of Contents

ToString Method

Definition

ToString(IDecorator<NameValueCollection>, FieldValueSeparator, bool)

Returns a string that represents the enclosed NameValueCollection of the decorator.

public static string ToString(this IDecorator<NameValueCollection> decorator, FieldValueSeparator separator, bool urlEncode)

Parameters

decorator IDecorator<NameValueCollection>

The IDecorator<T> to extend.

separator FieldValueSeparator

The separator used to form the key-value pairs.

urlEncode bool

Specify true to encode the values of the enclosed NameValueCollection of the decorator into a URL-encoded string; otherwise, false. Default is false.

Returns

string

A string that represents the enclosed NameValueCollection of the decorator.

Exceptions

ArgumentNullException

decorator cannot be null.