Example #1
0
        public bool TryAdd(IAutoFillSectionEntry entry)
        {
            if (entries.First().IsSequenceOf(entry))
            {
                entries.Add(entry);
                return(true);
            }

            return(false);
        }
Example #2
0
        public bool IsSequenceOf(IAutoFillSectionEntry otherEntry)
        {
            var otherTextEntry = otherEntry as TextAutoFillSectionEntry;

            if (otherTextEntry == null)
            {
                return(false);
            }

            return(textLeftOfDigit.Equals(otherTextEntry.textLeftOfDigit) &&
                   textRightOfDigit.Equals(otherTextEntry.textRightOfDigit) &&
                   hasDigit == otherTextEntry.hasDigit);
        }
Example #3
0
 public AutoFillSection(IAutoFillSectionEntry entry)
 {
     entries.Add(entry);
 }
 public bool IsSequenceOf(IAutoFillSectionEntry otherEntry)
 {
     return(otherEntry is NullAutoFillSectionEntry);
 }