예제 #1
0
        public SpellChecker(string plainText, int cursorPosition = 0)
        {
            _plainText      = plainText;
            _cursorPosition = Normalize(plainText, cursorPosition);
            _textChecker    = new UITextChecker();

            MisspelledWords = new RunOnceSequence <NSRange>(new MisspelledWordsSequence(_textChecker, plainText));
        }
예제 #2
0
        public void Test()
        {
            var i = 0;

            var s      = new EnumerableSequence <int>(new [] { 0, 1, 2, 3 }.Select(x => i++), 4);
            var cached = new RunOnceSequence <int>(s);

            var two  = cached.Take(2).ToArray();
            var all  = cached.ToArray();
            var all2 = cached.ToArray();

            var result  = s.ToArray();
            var result2 = s.ToArray();
        }