added CodeGenerator class