import { type DbcEntrySchema, type DbcIssueCode, type DbcParser, type DbcSchema } from '../../dbc-parser.types.js'; type ParsedEntryWithLine = DbcEntrySchema & { line: number; }; /** * @purpose Parses JSDoc-like contract blocks into a universal DBC schema and validates contract rules. * @implements {DbcParser} in ../../dbc-parser.types.ts * @invariant Input is handled line-by-line with explicit support for leading `*` markers. */ export declare class DbcJsDocParser implements DbcParser { /** * @param inputContract Raw contract text to parse. * @returns Parsed DBC schema with entries and format metadata. * @see {DbcParser#parse} in ../../dbc-parser.types.ts */ parse(inputContract: string): DbcSchema; /** * @purpose Normalizes a raw source line by stripping JSDoc framing tokens and edge whitespace. * @param sourceLine Raw line from the input contract. * @returns Line prepared for tag and multiline-value parsing. */ protected normalizeLine(sourceLine: string): string; /** * @purpose Parses a normalized tag line into an entry object with a source line reference. * @param tagLine Normalized line starting with `@`. * @param line One-based source line number. * @returns Parsed entry or undefined when the tag name is missing. */ protected parseTagLine(tagLine: string, line: number): ParsedEntryWithLine | undefined; /** * @purpose Parses tags where `{dataType}` is optional and the remainder is a plain value. * @param type Tag type. * @param tail Content after the tag name. * @param line One-based source line number. * @returns Parsed entry. */ protected parseTagWithOptionalDataType(type: string, tail: string, line: number): ParsedEntryWithLine; /** * @purpose Parses `@param` into `dataType`, optional `specifier`, `optional`, and value fields. * @param type Tag type. * @param tail Content after `@param`. * @param line One-based source line number. * @returns Parsed entry. */ protected parseParamTag(type: string, tail: string, line: number): ParsedEntryWithLine; /** * @purpose Parses `@see` into required `{specifier}` and optional trailing value. * @param type Tag type. * @param tail Content after `@see`. * @param line Source line number. * @returns Parsed entry. */ protected parseSeeTag(type: string, tail: string, line: number): ParsedEntryWithLine; /** * @purpose Parses `@implements` into required `{ContractName}` and optional trailing value. * @param type Tag type. * @param tail Content after `@implements`. * @param line One-based source line number. * @returns Parsed entry. */ protected parseImplementsTag(type: string, tail: string, line: number): ParsedEntryWithLine; /** * @purpose Emits a conflict issue when `purpose` and `see` are both present in the parsed entries. * @param entries Parsed entries with source lines. */ protected validatePurposeConflict(entries: ParsedEntryWithLine[]): void; /** * @purpose Verifies that contract tags follow the strict sequence required by the DBC standard. * @param entries Parsed entries with source lines. */ protected validateContractOrder(entries: ParsedEntryWithLine[]): void; /** * @purpose Emits missing-parameter-name issues for `@param` entries without a non-empty specifier. * @param entries Parsed entries with source lines. */ protected validateParamSpecifier(entries: ParsedEntryWithLine[]): void; /** * @purpose Emits invalid-see-format issues for `@see` entries. * @param entries Parsed entries to validate. */ protected validateSeeSpecifier(entries: ParsedEntryWithLine[]): void; /** * @purpose Adds an issue to a specific entry and preserves the entry start line in diagnostics. * @param entry Parsed entry with source line. * @param code Stable parser issue code. */ protected attachIssue(entry: ParsedEntryWithLine, code: DbcIssueCode): void; } export {};