import { DIC, NameBase } from './type' import { Finder as FinderBase } from './finder' import { Set as SetBase } from './set' import { Map as MapBase } from './map' import { Query as QueryBase } from './query' export const Name: DIC = {} export const Set: DIC> = {} export const Map: DIC> = {} export const Query: DIC> = {} export const Finder: DIC> = {} export function merge(o: DIC) { for (const key in o) { if (Query[key]) { const sk = Name[key].base const val = o[key] Set[sk].merge(val) } if (Set[key]) { const val = o[key] Set[key].append(val) } } }