All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.mongodb.hadoop.io.DataOutputOutputStreamAdapter Maven / Gradle / Ivy

Go to download

The MongoDB Connector for Hadoop is a plugin for Hadoop that provides the ability to use MongoDB as an input source and/or an output destination.

There is a newer version: 2.0.2
Show newest version
package com.mongodb.hadoop.io;

import java.io.DataOutput;
import java.io.IOException;
import java.io.OutputStream;

class DataOutputOutputStreamAdapter extends OutputStream {
    private final DataOutput dataOutput;

    DataOutputOutputStreamAdapter(final DataOutput dataOutput) {
        this.dataOutput = dataOutput;
    }

    @Override
    public void write(final int b) throws IOException {
        dataOutput.write(b);
    }

    @Override
    public void write(final byte[] b) throws IOException {
        dataOutput.write(b);
    }

    @Override
    public void write(final byte[] b, final int off, final int len) throws IOException {
        dataOutput.write(b, off, len);
    }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy