Move TextCodec classes to std::unique_ptr