Java File Copy nio copy(File src, File dst)

Here you can find the source of copy(File src, File dst)

Description

copy

License

Open Source License

Declaration

public static void copy(File src, File dst) throws IOException 

Method Source Code

//package com.java2s;
/*******************************************************************************
 * Copyright (c) 2014,2015 Hideki Yatomi
 * All rights reserved. This program and the accompanying materials are made
 * available under the terms of the Eclipse Public License v1.0 which
 * accompanies this distribution, and is available at
 * http://www.eclipse.org/legal/epl-v10.html
 ******************************************************************************/

import java.io.*;

import java.nio.file.*;

public class Main {
    public static void copy(File src, File dst) throws IOException {
        Files.copy(src.toPath(), dst.toPath(), StandardCopyOption.REPLACE_EXISTING);
    }//from   ww  w  . j a  v a  2 s.com
}

Related

  1. copy(File src, File dest)
  2. copy(File src, File dest)
  3. copy(File src, File dist)
  4. copy(File src, File dst)
  5. copy(File src, File dst)
  6. copy(File src, File dst)
  7. copy(File src, File folder)
  8. copy(File src, File target)
  9. copy(File src, File target)