UNPKG

@anchor-solutions-nl/translator-as

Version:
21 lines (20 loc) 722 B
import { Label, ITranslatorConfigOptions, TranslatorApp, IAddLabelResponse, ITranslationStore } from './models'; /** * This label queue class */ export declare class LabelSaverQueue { private readonly BATCH_SIZE; private queue; options: ITranslatorConfigOptions; app: TranslatorApp; inMemoryStore: ITranslationStore; private interval; constructor(options: ITranslatorConfigOptions); private getBatch; private startWatch; private stopWatch; addToQueue(label: Label): void; savelabel(label: Label): Promise<IAddLabelResponse>; updateLabelToServer(label: Label): Promise<IAddLabelResponse>; saveTranslatorApp(app: TranslatorApp): Promise<void>; }