Esempio n. 1
0
 internal void SetLastCharacterAsExplicitNonDelimiter()
 {
     if (this.Value.Length == 0)
     {
         throw new InvalidOperationException("This token has no value");
     }
     ExplicitNonDelimiterCharacters.Add(this.Value.Length - 1);
 }
Esempio n. 2
0
        internal bool EndsWithDelimiter(string delimiter)
        {
            if (this.Value.EndsWith(delimiter) == false)
            {
                return(false);
            }

            var firstTokenValue = this.Value.Substring(0, this.Value.Length - delimiter.Length);

            for (var i = firstTokenValue.Length; i < this.Value.Length; i++)
            {
                if (ExplicitNonDelimiterCharacters.Contains(i))
                {
                    return(false); // TODO - P0 - no code coverage for this case
                }
            }

            return(true);
        }