python2igcse
Version:
Convert Python code to IGCSE Pseudocode format
66 lines • 1.75 kB
TypeScript
import { PythonParser } from './python-parser';
import { ParserOptions } from '../types/parser';
/**
* Parser type
*/
export type ParserType = 'python' | 'javascript' | 'java' | 'cpp';
/**
* Parser factory configuration
*/
export interface ParserFactoryOptions {
/** Parser type */
type: ParserType;
/** Parser options */
options?: ParserOptions;
}
/**
* Parser factory class
*/
export declare class ParserFactory {
/**
* Create parser
*/
static create(config: ParserFactoryOptions): PythonParser;
/**
* Get list of supported parsers
*/
static getSupportedParsers(): ParserType[];
/**
* Check if parser is supported
*/
static isSupported(type: ParserType): boolean;
}
/**
* Convenience function: Create Python parser
*/
export declare function createParser(options?: ParserOptions): PythonParser;
/**
* Convenience function: Create preconfigured parser
*/
export declare function createPreconfiguredParser(preset: 'strict' | 'lenient' | 'debug'): PythonParser;
/**
* Get parser capabilities
*/
export declare function getParserCapabilities(type: ParserType): {
supportedFeatures: string[];
limitations: string[];
recommendedUse: string;
};
/**
* Parser benchmark information
*/
export interface ParserBenchmark {
/** Parser type */
type: ParserType;
/** Average parse time (milliseconds/line) */
avgParseTimePerLine: number;
/** Memory usage (MB/1000 lines) */
memoryUsagePer1000Lines: number;
/** Maximum recommended lines */
maxRecommendedLines: number;
}
/**
* Get parser benchmark information
*/
export declare function getParserBenchmark(type: ParserType): ParserBenchmark;
//# sourceMappingURL=factory.d.ts.map