Split Into Library and Application

- Split the solution into a console app and a class library.
- Modified the app config to allow .NET 4.0 support (since backward compatibility breakage between 3.5-4.0).