import java.net.InetSocketAddress ; import java.io.* ; import java.nio.channels.* ; public class CreateChannels { public static void main(String [] args) throws IOException { InetSocketAddress addr = new InetSocketAddress("www.grid2004.org", 80) ; SocketChannel sc = SocketChannel.open(addr) ; // Create a socket channel. RandomAccessFile raf = new RandomAccessFile("CreateChannels.class", "r") ; FileChannel fc = raf.getChannel() ; // Get a file channel. } }