EncodeFragment Method
Definition
EncodeFragment(QueryFormat, IEnumerable<string>, bool)
Encodes the specified sequence of values into the desired format of fragments.
public static string EncodeFragment(QueryFormat format, IEnumerable<string> values, bool distinct = false)
Parameters
formatQueryFormatOne of the enumeration values that specifies the fragment to produce.
valuesIEnumerable<string>The IEnumerable<T> to convert into the desired
formatof fragments.distinctboolif set to
true,valueswill be filtered for doublets.
Returns
- string
A query fragment in the desired format.
Exceptions
- ArgumentNullException
valuescannot be null.- ArgumentException
valuescontains no elements.