Here you can find the source of writeFileData(File file, byte[] fileData)
Parameter | Description |
---|---|
file | Description of the Parameter |
fileData | Description of the Parameter |
Parameter | Description |
---|
public static void writeFileData(File file, byte[] fileData) throws IOException
//package com.java2s; /*//from w w w . j av a2 s. c om * Copyright (c) Fiorano Software and affiliates. All rights reserved. http://www.fiorano.com * The software in this package is published under the terms of the CPAL v1.0 * license, a copy of which has been included with this distribution in the * LICENSE.txt file. */ import java.io.*; public class Main { /** * Writes the specified data to the specified fie * * @param file Description of the Parameter * @param fileData Description of the Parameter * @throws java.io.IOException Description of the Exception * @throws java.io.FileNotFoundException Description of the Exception */ public static void writeFileData(File file, byte[] fileData) throws IOException { BufferedOutputStream bos = new BufferedOutputStream( new FileOutputStream(file)); bos.write(fileData); bos.close(); } }