 | StringArrayExtensionsContains Method (String, String) |
Determines if any of the items in the specified data array match
the specified key using the current culture's string comparison settings.
Namespace:
TestHelperExtensions
Assembly:
CBI.TestHelperExtensions (in CBI.TestHelperExtensions.dll) Version: 2.1.0.1
Syntaxpublic static bool Contains(
this string[] dataArray,
string key
)
<ExtensionAttribute>
Public Shared Function Contains (
dataArray As String(),
key As String
) As Boolean
public:
[ExtensionAttribute]
static bool Contains(
array<String^>^ dataArray,
String^ key
)
[<ExtensionAttribute>]
static member Contains :
dataArray : string[] *
key : string -> bool
Parameters
- dataArray
- Type: SystemString
A list of string values. - key
- Type: SystemString
The value being searched for in the list of strings.
Return Value
Type:
BooleanA boolean indicating if the key value was found in the list of values.
Usage Note
In Visual Basic and C#, you can call this method as an instance method on any object of type . When you use instance method syntax to call this method, omit the first parameter. For more information, see
Extension Methods (Visual Basic) or
Extension Methods (C# Programming Guide).
See Also