| ConditionMethodsContains Method |
Gets or sets a value indicating whether the second string is a substring of the first one.
Namespace:
NLog.Conditions
Assembly:
NLog (in NLog.dll) Version: 5.3.4+73d83d3161d31288ca5c554cc50d27b6bed5f28b
Syntax public static bool Contains(
string haystack,
string needle,
bool ignoreCase = true
)
Public Shared Function Contains (
haystack As String,
needle As String,
Optional ignoreCase As Boolean = true
) As Boolean
Dim haystack As String
Dim needle As String
Dim ignoreCase As Boolean
Dim returnValue As Boolean
returnValue = ConditionMethods.Contains(haystack,
needle, ignoreCase)
static member Contains :
haystack : string *
needle : string *
?ignoreCase : bool
(* Defaults:
let _ignoreCase = defaultArg ignoreCase true
*)
-> bool
Parameters
- haystack
- Type: SystemString
The first string. - needle
- Type: SystemString
The second string. - ignoreCase (Optional)
- Type: SystemBoolean
Optional. If true (default), case is ignored; if false, case is significant.
Return Value
Type:
Booleantrue when the second string is a substring of the first string,
false otherwise.
See Also