add logic for pure entity expose
more testcase
refactor and support pure map