import { ITokenizer } from 'strtok3/lib/core' ; import { ITokenParser } from '../ParserFactory' ; import { IOptions , IPrivateOptions } from '../type' ; import { INativeMetadataCollector } from './MetadataCollector' ; export abstract class BasicParser implements ITokenParser { protected metadata : INativeMetadataCollector ; protected tokenizer : ITokenizer ; protected options : IPrivateOptions ; param { INativeMetadataCollector } metadata param { ITokenizer } tokenizer param { IOptions } options public init ( metadata , tokenizer , options ) { this . metadata = metadata ; this . tokenizer = tokenizer ; this . options = options ; return this ; } public abstract parse ( ) ; }