Class version of code added. Not finished.
remove old file.