public static BlockOutStream createReplicatedBlockOutStream(FileSystemContext context,
      long blockId, long blockSize, java.util.List<WorkerNetAddress> workerNetAddresses,
      OutStreamOptions options) throws IOException {
    List<DataWriter> dataWriters = new ArrayList<>();
    for (WorkerNetAddress address: workerNetAddresses) {
      DataWriter dataWriter =
            DataWriter.Factory.create(context, blockId, blockSize, address, options);
      dataWriters.add(dataWriter);
    }
    return new BlockOutStream(dataWriters, blockSize, workerNetAddresses);
  }
public static BlockOutStream createReplicatedBlockOutStream ( FileSystemContext context , long blockId , long blockSize , java . util . List < WorkerNetAddress > workerNetAddresses , OutStreamOptions options ) throws IOException { List < DataWriter > dataWriters = new ArrayList < > ( ) ; for ( WorkerNetAddress address : workerNetAddresses ) { DataWriter dataWriter = DataWriter . Factory . create ( context , blockId , blockSize , address , options ) ; dataWriters . add ( dataWriter ) ; } return new BlockOutStream ( dataWriters , blockSize , workerNetAddresses ) ; }
Creates a new remote block output stream.

@param context the file system context
@param blockId the block id
@param blockSize the block size
@param workerNetAddresses the worker network addresses
@param options the options
@return the {@link BlockOutStream} instance created