(json: string)
| 44 | }; |
| 45 | |
| 46 | public import(json: string): boolean { |
| 47 | try { |
| 48 | const { leafMap, disabledHosts } = JSON.parse(json); |
| 49 | this.disabledHosts = new Set(disabledHosts); |
| 50 | this.store = leafMapToRouterMap(leafMap); |
| 51 | this.leafMap = leafMap; |
| 52 | return true; |
| 53 | } catch { |
| 54 | return false; |
| 55 | } |
| 56 | } |
| 57 | |
| 58 | public export = (): string => { |
| 59 | return stringify({ |
no outgoing calls
no test coverage detected