* Creates a clone of type options base. * * @returns {TypeOptionsBase } Type options base clone.
()
| 809 | * @returns {TypeOptionsBase<any>} Type options base clone. |
| 810 | */ |
| 811 | private cloneTypeOptionsBase(): TypeOptionsBase<any> |
| 812 | { |
| 813 | const typeOptionsBase = this.typeOptionsBase; |
| 814 | const customValueMap = typeOptionsBase.customValueMap; |
| 815 | const customValueMapClone = new Map<CustomKey<any>, CustomValue>(); |
| 816 | const typeOptionsBaseClone = Object.assign({}, typeOptionsBase, { customValueMap: customValueMapClone }); |
| 817 | |
| 818 | for (const [customKey, customValue] of customValueMap) |
| 819 | { |
| 820 | customValueMapClone.set(customKey, customValue); |
| 821 | } |
| 822 | |
| 823 | return typeOptionsBaseClone; |
| 824 | } |
| 825 | |
| 826 | /** |
| 827 | * Creates a clone of type options map. |