Set the current state of the encoder. state must have been returned by getstate().
codecs/IncrementalEncoder.setstate
IncrementalEncoder.setstate