/** * QR Matrix Management */ import type { BitMatrix } from "../types/index.js"; export declare class Matrix implements BitMatrix { readonly size: number; private data; constructor(size: number); /** * Internal access to raw data for performance-critical operations (e.g. penalty calculation). */ get _data(): Uint8Array; /** * Returns cell value (Only 0 or 1) */ get(x: number, y: number): 0 | 1; /** * Checks whether a cell is "Reserved" */ isReserved(x: number, y: number): boolean; /** * Sets the cell and reserves it (for functional patterns) */ setReserved(x: number, y: number, isDark: boolean): void; /** * Only for data modules (Writes to unreserved areas) */ set(x: number, y: number, isDark: boolean): void; /** * RFC 5.2: Returns the matrix as rows */ toRows(): ReadonlyArray; /** * RFC 5.2: Returns matrix as a packed (MSB-first) byte array */ toPacked(): Uint8Array; clone(): Matrix; } export declare class ReadOnlyMatrix implements BitMatrix { readonly size: number; private readonly inner; constructor(matrix: Matrix); get(x: number, y: number): 0 | 1; toRows(): ReadonlyArray; toPacked(): Uint8Array; }