Rework replacement string to use Java string, target charset.

We originally passed around a Ruby string with no specified
encoding, but this appeared to decode into invalid replacement
bytes under some encodings. Since we always want to replace with
the '?' character (rather than e.g. the unicode <?> character in
UTF-16), I altered the replaceWith field of CodingErrorActions to
be a plain String, and added the target charset to getBytes.

Fixes #375.
Fixes #861 (same cause).