DFSMap constructor implementation