Reworking classes for data layer.