Class QueryFormatExtensions
- Namespace
- Cuemon.Extensions.Data
- Assembly
- Cuemon.Extensions.Data.dll
Extension methods for the QueryFormat enum.
public static class QueryFormatExtensions
- Inheritance
-
QueryFormatExtensions
Methods
Embed(QueryFormat, IEnumerable<Int32>, Boolean)
Embeds the specified Int32 sequence within the desired query fragment format.
public static string Embed(this QueryFormat format, IEnumerable<int> values, bool distinct = false)
Parameters
format
QueryFormatThe QueryFormat to extend.
values
IEnumerable<Int32>The values to be generated in the specified format for the query fragment.
distinct
Booleanif set to
true
,values
will be filtered for doublets.
Returns
- String
A query fragment in the desired format.
Embed(QueryFormat, IEnumerable<Int64>, Boolean)
Embeds the specified Int64 sequence within the desired query fragment format.
public static string Embed(this QueryFormat format, IEnumerable<long> values, bool distinct = false)
Parameters
format
QueryFormatThe QueryFormat to extend.
values
IEnumerable<Int64>The values to be generated in the specified format for the query fragment.
distinct
Booleanif set to
true
,values
will be filtered for doublets.
Returns
- String
A query fragment in the desired format.
Embed(QueryFormat, IEnumerable<String>, Boolean)
Embeds the specified String sequence within the desired query fragment format.
public static string Embed(this QueryFormat format, IEnumerable<string> values, bool distinct = false)
Parameters
format
QueryFormatThe QueryFormat to extend.
values
IEnumerable<String>The values to be generated in the specified format for the query fragment.
distinct
Booleanif set to
true
,values
will be filtered for doublets.
Returns
- String
A query fragment in the desired format.
Exceptions
- ArgumentNullException
values
cannot be null.- ArgumentException
values
contains no elements.