mysql connection class and connection method