added namespace support and autoload class