Pr/3098

I've fixed up https://github.com/silverstripe/silverstripe-framework/pull/3098, rebased it, squashed the commits, fixed the test cases, and made a few API suggestions.
Looks like my point is moot given https://github.com/silverstripe/silverstripe-framework/pull/3511/files#r18083174 as I was thinking the new features weren't finding their way through to `Cookie`, but they are now.

But this means some new tests for `Cookie` need to go in