Extractor enabling patterns that match MatchResult
having matches
property value of false
,
extracting the contained failure message.
Extractor enabling patterns that match MatchResult
having matches
property value of false
,
extracting the contained failure message.
For example, you can use this extractor to get the failure message of a MatchResult
like this:
matchResult match {
case MatchFailed(failureMessage) => // do something with failureMessage
case _ => // when matchResult.matches equal to true
}
the MatchResult
to extract the failure message from.
a Some
wrapping the contained failure message if matchResult.matches
is equal to true
, else None
.
Singleton object that provides
unapply
method to extract failure message fromMatchResult
havingmatches
property value offalse
.