Refactored UserAgentHeader class