We can't use a separate `clear` method - an update has to be atomic.

I'll change the logic so that a null argument, or a single null element means 'clear'; I'll also add a javadoc example.