Code example for CharBuffer

Methods: toString

0
is = new FileInputStream( file );
            FileChannel ch = is.getChannel();
            MappedByteBuffer mb = ch.map( MapMode.READ_ONLY, 0L, ch.size() );
            CharBuffer charBuffer = decoder.decode( mb );
            return charBuffer.toString();
        } 
        finally 
        { 
            IOUtil.close( is );
        } 
    } 
 
} 
Stop searching for code, let great code find you!  Add Codota to your java IDE