/** * Strict UTF-8 validation on a buffer. * TextDecoder with fatal: true throws an error on invalid UTF-8 sequences. */ export declare function isValidUTF8(buffer: Buffer): boolean; /** * Returns true if the file consistently uses CRLF. * Consistently means it contains at least one CRLF, and no LF without a preceding CR. */ export declare function isConsistentlyCRLF(text: string): boolean; /** * Preservation of BOM and line endings. */ export declare function applyEncodingPreservation(existingContent: string, newContent: string): string; /** * Get the byte length of a string in UTF-8. */ export declare function utf8ByteLength(text: string): number; //# sourceMappingURL=file-encoding-policy.d.ts.map