import CallToActionHashMap from "../../../../src/services/scoringSystem/callToActionHashMap.service"; import { NormStats } from "../../../../src/services/scoringSystem/abstractScoreHashMap.service"; export interface CtaMaps { scoresMap: Map; // format, ssp, campaing_id, app -> cta_score normMap: Map; // campaign_id -> average cta_score } export default class CallToActionHashMapFake extends CallToActionHashMap { static fromCtaMaps(ctaMaps: CtaMaps) { const cta = new CallToActionHashMapFake(); cta.onRefreshSuccess(ctaMaps.scoresMap, ctaMaps.normMap, new Date()); return cta; } setS3Prefix(s3Prefix: string) { this.s3Prefix = s3Prefix; } setMaxRetries(maxRetries: number) { this.maxRetries = maxRetries; } async runRefresh() { return this.refreshMaps(); } }