Update server and client for changes in Headers mutability.
Fixed a race condition in `get_ref`

If two threads attempted to `get_ref` the same Header under two
representations, then it was possible that the second thread would
overwrite the work of the first thread, causing the first thread
to do an unchecked downcast to the wrong type.

In the case where they were the same Header representation, then the
only damage would be that it would be parsed twice and would possibly
return a false negative in one thread.

The new code checks that it was not a queued lock and will not override
the work of another thread, but will accept it if the other thread parsed
the header as the same type. This also prevents duplicate parsing.
Remove get and rename get_ref to get

Since `get_ref` (now `get`) takes `&self` there is no need
for a special cloning method.
Add get_mut for modifying the typed representation of Headers.

Also adds an associated test and updates code to use it instead
of cloning and setting when possible.