Replaced enum throw with Exception class

Should remove the const strings too.