/** * Validation framework for LeanSpec specs * * Provides a plugin architecture for adding validation rules. * Each validator checks specific aspects of specs and returns results. */ import type { SpecInfo } from '../types/index.js'; /** * Result of a single validation check */ export interface ValidationError { message: string; suggestion?: string; } export interface ValidationWarning { message: string; suggestion?: string; } export interface ValidationResult { passed: boolean; errors: ValidationError[]; warnings: ValidationWarning[]; } /** * A validation rule that can be registered with the framework */ export interface ValidationRule { name: string; description: string; validate(spec: SpecInfo, content: string): ValidationResult | Promise; } /** * Registry for validation rules */ export declare class ValidationRegistry { private rules; /** * Register a new validation rule */ registerRule(rule: ValidationRule): void; /** * Get a specific rule by name */ getRule(name: string): ValidationRule | undefined; /** * Get all registered rules */ getAllRules(): ValidationRule[]; /** * Get all rule names */ getRuleNames(): string[]; /** * Check if a rule is registered */ hasRule(name: string): boolean; } /** * Global registry instance */ export declare const validationRegistry: ValidationRegistry; //# sourceMappingURL=validation-framework.d.ts.map