public class MyClassLoaderTest {
public static void main(String[] args) throws Exception{
String srcPath =args[0];//请问这个args[0]和args[1]是从哪取得值呀
String destPath =args[1];
FileInputStream fis = new FileInputStream(srcPath);
String destFileName =srcPath.substring(srcPath.lastIndexOf('\\')+1);
String destFilePath = destPath+"\\"+destFileName;
FileOutputStream fos = new FileOutputStream(destFilePath);
cypher(fis,fos);
fos.close();
fis.close();
}
private static void cypher(InputStream ips,OutputStream ops) throws Exception{
int b =-1;
while((b=ips.read())!=-1){
ops.write(b^0xff);
}
}
}
|
|