public RiverVersionZeroMarshallerFactoryTestMarshallerProviderImpl(final MarshallerFactory factory) {
super(factory, 0);
}
public Marshaller create(final MarshallingConfiguration config, final ByteOutput target) throws IOException {
final StreamHeader header = config.getStreamHeader();
config.setStreamHeader(new StreamHeader() {
public void readHeader(final ByteInput input) throws IOException {
if (header != null) header.readHeader(input);
}
public void writeHeader(final ByteOutput output) throws IOException {
if (header != null) header.writeHeader(output);
output.write(0);
}
});
return super.create(config, target);
}