Java Reader Copy copyLarge(Reader input, Writer output)

Here you can find the source of copyLarge(Reader input, Writer output)

Description

copy Large

License

Apache License

Declaration

public static long copyLarge(Reader input, Writer output) throws IOException 

Method Source Code


//package com.java2s;
//License from project: Apache License 

import java.io.*;

public class Main {
    public static long copyLarge(Reader input, Writer output) throws IOException {
        char[] buffer = new char[4096];
        long count = 0L;

        int n1;/*  w  w  w. j  a  v a 2s .com*/
        for (; -1 != (n1 = input.read(buffer)); count += (long) n1) {
            output.write(buffer, 0, n1);
        }

        return count;
    }
}

Related

  1. copyLarge(Reader input, Writer output)
  2. copyLarge(Reader input, Writer output)
  3. copyLarge(Reader input, Writer output)
  4. copyLarge(Reader input, Writer output)
  5. copyLarge(Reader input, Writer output)
  6. copyLarge(Reader input, Writer output)
  7. copyLarge(Reader input, Writer output)
  8. copyLarge(Reader input, Writer output)
  9. copyLarge(Reader input, Writer output)