src/org/kocakosm/pitaya/io/XFiles.java
public static void mv(File src, File dst) throws IOException
	{
		Parameters.checkNotNull(dst);
		if (!src.equals(dst)) {
			cp(src, dst);
			try {
				rm(src);
			} catch (IOException e) {
				rm(dst);
				throw new IOException("Can't move " + src, e);
			}
		}
	}
public static void mv(File src, File dst) throws IOException
	{
		Parameters.checkNotNull(dst);
		if (!src.equals(dst)) {
			cp(src, dst);
			try {
				rm(src);
			} catch (IOException e) {
				rm(dst);
				throw new IOException("Can't move " + src, e);
			}
		}
	}
public static void mv ( File src , File dst ) throws IOException { Parameters . checkNotNull ( dst ) ; if ( ! src . equals ( dst ) ) { cp ( src , dst ) ; try { rm ( src ) ; } catch ( IOException e ) { rm ( dst ) ; throw new IOException ( "Can't move " + src , e ) ; } } }
Moves a file from one path to another. Named after the Unix command
of the same name.

@param src the original file.
@param dst the destination path.

@throws NullPointerException if one of the arguments is {@code null}.
@throws IllegalArgumentException if {@code src} is a directory and
{@code dst} is a regular file.
@throws IOException if {@code src} can't be moved to {@code dst}.
@throws SecurityException if a security manager exists and denies
read/write access to {@code src}/{@code dst}.
Moves a file from one path to another . Named after the Unix command of the same name .