System.Management.Pash.Implementation.ExecutionVisitor.NotMatch C# (CSharp) Method

NotMatch() private method

private NotMatch ( object leftOperand, object rightOperand, RegexOptions regexOptions ) : bool
leftOperand object
rightOperand object
regexOptions RegexOptions
return bool
        private bool NotMatch(object leftOperand, object rightOperand, RegexOptions regexOptions)
        {
            if (!(leftOperand is string) || !(rightOperand is string))
                throw new NotImplementedException(string.Format("{0} -match {1}", leftOperand, rightOperand));

            Regex regex = new Regex((string)rightOperand, regexOptions);
            Match match = regex.Match((string)leftOperand);

            return !match.Success;
        }
ExecutionVisitor