public DataOutputStream createDataOutputStream ( FSDataOutputStream outputStream ) throws IOException { if ( codec != null ) { return new FSDataOutputStream ( codec . createOutputStream ( outputStream ) , null ) ; } else { return outputStream ; } }
Create a DataOutputStream from FSDataOutputStream . If the codec is available it will create compressed DataOutputStream otherwise it will return itself .