传上去? 什么意思?~  ctrl+c ctrl+v 就可以了吧~~~
比如像这样:
public void fileCopy(String a,String b){
File file = new File(a);
if(! file.exists()){
System.out.println(a +"Not exists.");
}
File fileb = new File(b);
if(file.isFile()){
FileInputStream fis = null;
FileOutputStream fos = null;
try{
fis = new FileInputStream(file);
fos = new FileOutputStream(fileb);

byte[] bb = new byte[(int)file.length()];
fis.read(bb);
fos.write(bb);
}catch(IOException e){
e.printStackTrace();

}finally{
try{
fis.close();
fos.close();
}catch(IOException e){
e.printStackTrace();
}
}
}else if(file.isDirectory()){
if(!fileb.exists()){
fileb.mkdir();
}
String[] fileList;
fileList = file.list();
for(int i = 0;i<fileList.length;i++){
fileCopy(a + "\\" + fileList[i],b + "\\" + fileList[i]);
}
}
}
public static void main(String[]arg){
TS t = new TS();
t.fileCopy("a.txt","Test.txt");
}