Restructed some thangs.
Removed some unused classes.
Started to restructure the resource class.