1 line
1.6 KiB
JavaScript
1 line
1.6 KiB
JavaScript
"use strict";(self.webpackChunktradingview=self.webpackChunktradingview||[]).push([[2757],{34962:(e,o,r)=>{r.d(o,{ChartStorageExternalAdapter:()=>s});class s{constructor(e){this._externalAdapter=e,this._externalAdapter.saveLineToolsAndGroups&&this._externalAdapter.loadLineToolsAndGroups||console.warn("saveLineToolsAndGroups and loadLineToolsAndGroups are required in the SaveLoad Adapter when `saveload_separate_drawings_storage` featureset is enabled.")}async saveLineToolsAndGroups(e,o,r,s,a){if(!this._externalAdapter.saveLineToolsAndGroups)throw new Error("saveLineToolsAndGroups should be implemented within the SaveLoad Adapter when `saveload_separate_drawings_storage` featureset is enabled.");if(void 0===e)throw new Error("Cannot save line tools without a layout");const t={sharingMode:s,requestId:`${e}:${o}`,symbol:r.symbol};return await this._externalAdapter.saveLineToolsAndGroups(e,o,r,t),{chartId:o,content:"",layoutId:e,savedDto:r,sharingMode:s}}async loadLineToolsAndGroups(e,o,r){if(!this._externalAdapter.loadLineToolsAndGroups)throw new Error("loadLineToolsAndGroups should be implemented within the SaveLoad Adapter when `saveload_separate_drawings_storage` featureset is enabled.");const s={};s.sharingMode=r.sharingMode,"seriesSourceId"in r&&(s.seriesSourceId=r.seriesSourceId),"mainSeriesLineTools"===r.requestType&&(s.symbol=r.symbol);return await this._externalAdapter.loadLineToolsAndGroups(e,o,r.requestType,s)}removeLineTools(e,o,r,s){throw new Error("Method not implemented.")}getLayoutDrawingsSizeInfo(e,o){throw new Error("Method not implemented.")}getUserGlobalDrawingsSizeInfo(e){throw new Error("Method not implemented.")}}}}]); |