UNPKG

@rep2recall/r2r-format

Version:

R2r (offline/online) abstract class for Rep2Recall

20 lines (17 loc) 654 B
import { R2rFormat } from "./format"; export * from "./util"; export abstract class R2rLocal extends R2rFormat { public filename: string; constructor(filename: string) { super(); this.filename = filename; } } export abstract class R2rOnline extends R2rFormat { abstract async signup(username: string, password?: string): Promise<string>; abstract async getSecret(): Promise<string | null>; abstract async newSecret(): Promise<string | null>; abstract async parseSecret(secret: string): Promise<boolean>; abstract async login(username: string, password?: string): Promise<boolean>; abstract async logout(): Promise<boolean>; }