include("import") func doConnect(_data) // TODO fvar(ct) ct = ConnType need_MySQLdb() print(con, ' = MySQLdb.connect(') if (ct == 0) //TCP print('host = ', Host, ', port = ', Port) end if (ct == 1) //Unix print('unix_socket = ', UnixSocket) end if (ct == 2) //named pipe print('named_pipe = True') end println(', user = ', Username, ', pass = ', Password, ')') event(onConnect, con) end func Connection(_data) return con end