public override bool Match(object a, object b)
        {
            var aString = CompareTypeUtils.CoerceString(a);
            var bString = CompareTypeUtils.CoerceString(b);

            return(string.Compare(aString, bString, StringComparison.InvariantCultureIgnoreCase) == 0);
        }
        public override bool Match(object a, object b)
        {
            var aString = CompareTypeUtils.CoerceString(a);
            var bString = CompareTypeUtils.CoerceString(b);

            if (aString == null || bString == null)
            {
                return(false);
            }
            return(aString.EndsWith(bString, StringComparison.InvariantCultureIgnoreCase));
        }
Ejemplo n.º 3
0
        public override bool Match(object a, object b)
        {
            var aString = CompareTypeUtils.CoerceString(a);
            var bString = CompareTypeUtils.CoerceString(b);

            if (aString == null || bString == null)
            {
                return(false);
            }
            return(aString.IndexOf(bString, StringComparison.OrdinalIgnoreCase) >= 0);
        }
 public virtual int CompareTo(object a, object b)
 {
     return(CompareTypeUtils.CompareTo(a, b));
 }