Exemplo n.º 1
0
        private void HandleLineEndings()
        {
            if (Configuration.RowEnding != Cesil.RowEndings.Detect)
            {
                RowEndings = Configuration.RowEnding;
                TryMakeStateMachine();
                return;
            }

            using (var detector = new RowEndingDetector <T>(Configuration, SharedCharacterLookup, Inner))
            {
                var res = detector.Detect();
                HandleLineEndingsDetectionResult(res);
            }
        }
Exemplo n.º 2
0
        private void HandleLineEndings()
        {
            var options = Configuration.Options;

            if (options.ReadRowEnding != ReadRowEnding.Detect)
            {
                RowEndings = options.ReadRowEnding;
                TryMakeStateMachine();
                return;
            }

            using (var detector = new RowEndingDetector(StateMachine, options, Configuration.MemoryPool, SharedCharacterLookup, Inner, Configuration.ValueSeparatorMemory))
            {
                var res = detector.Detect();
                HandleLineEndingsDetectionResult(res);
            }
        }