StringValues.Implicit Operator

Definition

Overloads

Implicit(StringValues to String)

Defines an implicit conversion of a given StringValues to a string, with multiple values joined as a comma separated string.

Implicit(StringValues to String[])

Defines an implicit conversion of a given StringValues to a string array.

Implicit(String to StringValues)

Defines an implicit conversion of a given string to a StringValues.

Implicit(String[] to StringValues)

Defines an implicit conversion of a given string array to a StringValues.

Implicit(StringValues to String)

Source:
StringValues.cs
Source:
StringValues.cs
Source:
StringValues.cs

Defines an implicit conversion of a given StringValues to a string, with multiple values joined as a comma separated string.

C#
public static implicit operator string?(Microsoft.Extensions.Primitives.StringValues values);

Parameters

values
StringValues

A StringValues to implicitly convert.

Returns

Returns null where StringValues has been initialized from an empty string array or is Empty. Otherwise, it returns the implicit conversion of StringValues to a string.

Remarks

Returns null where StringValues has been initialized from an empty string array or is Empty.

Applies to

.NET 10 (package-provided) och andra versioner
Produkt Versioner
.NET 8 (package-provided), 9 (package-provided), 10 (package-provided)
.NET Standard 2.0 (package-provided)

Implicit(StringValues to String[])

Source:
StringValues.cs
Source:
StringValues.cs
Source:
StringValues.cs

Defines an implicit conversion of a given StringValues to a string array.

C#
public static implicit operator string?[]?(Microsoft.Extensions.Primitives.StringValues value);

Parameters

value
StringValues

A StringValues to implicitly convert.

Returns

String[]

Applies to

.NET 10 (package-provided) och andra versioner
Produkt Versioner
.NET 8 (package-provided), 9 (package-provided), 10 (package-provided)
.NET Standard 2.0 (package-provided)

Implicit(String to StringValues)

Source:
StringValues.cs
Source:
StringValues.cs
Source:
StringValues.cs

Defines an implicit conversion of a given string to a StringValues.

C#
public static implicit operator Microsoft.Extensions.Primitives.StringValues(string? value);

Parameters

value
String

A string to implicitly convert.

Returns

Applies to

.NET 10 (package-provided) och andra versioner
Produkt Versioner
.NET 8 (package-provided), 9 (package-provided), 10 (package-provided)
.NET Standard 2.0 (package-provided)

Implicit(String[] to StringValues)

Source:
StringValues.cs
Source:
StringValues.cs
Source:
StringValues.cs

Defines an implicit conversion of a given string array to a StringValues.

C#
public static implicit operator Microsoft.Extensions.Primitives.StringValues(string?[]? values);

Parameters

values
String[]

A string array to implicitly convert.

Returns

Applies to

.NET 10 (package-provided) och andra versioner
Produkt Versioner
.NET 8 (package-provided), 9 (package-provided), 10 (package-provided)
.NET Standard 2.0 (package-provided)