diff --git a/src/iscs_new/utils/Storage.js b/src/iscs_new/utils/Storage.js deleted file mode 100644 index d599a3d68..000000000 --- a/src/iscs_new/utils/Storage.js +++ /dev/null @@ -1,63 +0,0 @@ - -export default class Storage { - constructor() { - this.map = new Map(); - this.lst = new Set(); - this.clipboard = []; - } - - has(code) { - return code ? this.map.has(code) : false; - } - - set(code, target) { - if (!this.has(code)) { - this.lst.add(code); - this.map.set(code, target); - } - } - - get(code) { - return this.map.get(code); - } - - delete(code) { - if (this.has(code)) { - this.map.delete(code); - this.lst.delete(code); - } - } - - values() { - return Array.from(this.lst).map(code => { return this.get(code); }); - } - - clear() { - this.lst.clear(); - this.map.clear(); - } - - isSelectExist(code) { - return this.has(code); - } - - setClipboard(lst) { - this.clipboard = Array.from(lst); - } - - clearClipboard() { - this.clipboard = []; - } - - getClipboard() { - return this.clipboard; - } - - getClipboardSize() { - return this.clipboard.length; - } - - forEach() { - return this.map.forEach; - } -}