Move the rest duplicate codes of the data layers into their base class