Here you can find the source of write(SeekableByteChannel channel, long start, byte[] bytes)
static void write(SeekableByteChannel channel, long start, byte[] bytes) throws IOException
//package com.java2s; //License from project: Open Source License import java.io.IOException; import java.nio.ByteBuffer; import java.nio.channels.SeekableByteChannel; public class Main { static void write(SeekableByteChannel channel, long start, byte[] bytes) throws IOException { channel.position(start);/* www .j av a2s . c o m*/ ByteBuffer buffer = ByteBuffer.wrap(bytes); while (buffer.hasRemaining()) { channel.write(buffer); } } }