adding license information so it's free to use...
Cleanup the connection and moving string class into seperate file.