//private void _testLine(String line, fileTextSearchResult output, )

        /// <summary>
        /// Search file with multiple needles - performs search with multiple needles.
        /// </summary>
        /// <param name="__needles">Set of needles or regex expressions to evaluate lines with</param>
        /// <param name="useRegex">if set to <c>true</c> it will interpret the needle as regex</param>
        /// <param name="comparison">The comparison.</param>
        /// <param name="regexOptions">The regex options, used in combination with <c>useRegex</c> = true</param>
        /// <param name="limitResult">Result size limit (per needle) - it stops the search procedure once the limit is reached. Leave it -1 to disable the limit</param>
        /// <returns>Set of results</returns>
        public fileTextSearchResultSet Search(IEnumerable <String> __needles, Boolean useRegex = false, RegexOptions regexOptions = RegexOptions.None, Int32 limitResult = -1)
        {
            fileTextSearchResultSet output = new fileTextSearchResultSet(__needles, file.FullName, useRegex);
            fileTextOperaterWorker  eval   = new fileTextOperaterWorker(__needles, useRegex, regexOptions);
            var     map     = GetTextMap();
            Boolean limitOn = (limitResult > 0);

            ParallelOptions po = new ParallelOptions();

            Parallel.ForEach(map, po, block =>
            {
                Int32 l      = block.lineStart;
                String match = "";
                foreach (String line in block)
                {
                    if (eval.evaluate(line, out match))
                    {
                        output[match].Add(l, line, false);
                    }
                    l++;

                    if (limitOn && (output.CountThreadSafe >= limitResult))
                    {
                        output.resultLimitTriggered = true;
                        break;
                    }
                }
            });

            return(output);
        }
        /// <summary>
        /// Searches the specified cached lines.
        /// </summary>
        /// <param name="cachedLines">The cached lines.</param>
        /// <param name="__needle">The needle.</param>
        /// <param name="useRegex">if set to <c>true</c> [use regex].</param>
        /// <param name="limitResult">The limit result.</param>
        /// <param name="regexOptions">The regex options.</param>
        /// <returns></returns>
        public fileTextSearchResult Search(fileTextLineCollection cachedLines, String __needle, Boolean useRegex = false, Int32 limitResult = -1, RegexOptions regexOptions = RegexOptions.None)
        {
            fileTextSearchResult   output = new fileTextSearchResult(__needle, file.FullName, useRegex);
            fileTextOperaterWorker eval   = new fileTextOperaterWorker(__needle, useRegex, regexOptions);

            foreach (var lp in cachedLines)
            {
                String match = "";
                if (eval.evaluate(lp.Value, out match))
                {
                    output.Add(lp.Key, lp.Value, false);
                }

                if (output.CountThreadSafe > limitResult)
                {
                    output.resultLimitTriggered = true;
                    break;
                }
            }
            return(output);
        }