/** * Parses a single CSV line into an array of fields. * Handles quoted fields, escaped quotes, and custom delimiters. * * @param input - The CSV line to parse. * @param delimiter - Field delimiter (default: ","). * @param quote - Quote character (default: '"'). * @returns An array of parsed fields. * * @throws {Error} If input is empty. * @throws {Error} If delimiter or quote is not exactly one character. * @throws {Error} If quotes are not properly closed. * * @example * // Basic usage * parseCSVLine("a,b,c"); // Returns ["a", "b", "c"] * * @example * // Quoted fields * parseCSVLine('a,"b,c",d'); // Returns ["a", "b,c", "d"] * * @example * // Escaped quotes * parseCSVLine('a,"b""c",d'); // Returns ["a", 'b"c', "d"] * * @example * // Custom delimiter * parseCSVLine("a|b|c", "|"); // Returns ["a", "b", "c"] * * @example * // Empty fields * parseCSVLine("a,,c"); // Returns ["a", "", "c"] * * @note This function follows RFC 4180 CSV parsing rules. * Quoted fields can contain delimiters and newlines. * Quotes within quoted fields must be escaped by doubling them. * * @complexity Time: O(n), Space: O(n) - Where n is the length of input string */ export declare function parseCSVLine(input: string, delimiter?: string, quote?: string): string[]; //# sourceMappingURL=parseCSVLine.d.ts.map