Introduce UserAgentReader class + make code run on .NET 4

UserAgentReader encapsulates the various UserAgent checks in the code