Exemplo n.º 1
0
            internal override P WorkaroundLimitations(GremlinqOptions gremlinqOptions)
            {
                if ((gremlinqOptions.GetValue(GremlinqOption.DisabledTextPredicates) & DisabledTextPredicates.Containing) != 0)
                {
                    throw new ExpressionNotSupportedException();
                }

                return(base.WorkaroundLimitations(gremlinqOptions));
            }
Exemplo n.º 2
0
            internal override P WorkaroundLimitations(GremlinqOptions gremlinqOptions)
            {
                if ((gremlinqOptions.GetValue(GremlinqOption.DisabledTextPredicates) & DisabledTextPredicates.StartingWith) == 0)
                {
                    return(base.WorkaroundLimitations(gremlinqOptions));
                }

                string upperBound;

                if (Value[Value.Length - 1] == char.MaxValue)
                {
                    upperBound = Value + char.MinValue;
                }
                else
                {
                    var upperBoundChars = Value.ToCharArray();

                    upperBoundChars[upperBoundChars.Length - 1]++;
                    upperBound = new string(upperBoundChars);
                }

                return(new P.Between(Value, upperBound));
            }