ɾ³ý.svn .cvsµÈÎļþ¼ÐµÄjava´úÂë
ÏîÄ¿ÖÐÓеÄÎļþ¼ÐÔÀ´ÊÇsvn°æ±¾¿ØÖƵģ¬ÏÖÔÚ²»Ïë¿ØÖÆÁË£¬¾ÍÏñ°ÑÕâ¸öÎļþ¼Ð´«¸ø±ðÈË»òÕß×Ô¼º±¸·Ý£¬µ«ÊÇ¿´µ½ÄÇô¶à.svnÎļþ¼ÐʵÔÚ²»Êæ·þ£¬Ð´ÁËÏÂÃæµÄ¼òµ¥³ÌÐòÓÃÀ´É¾³ýÕâЩÎļþ£¬ÒÔºóÐèҪɾ³ýµÄ»°£¬ÉèÖúÃÎļþ¼Ð·¾¶ºÍҪɾ³ýµÄÎļþ¼ÐÃû×ÖÅÜһϾÍÐÐÁË¡£
import java.io.File;
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
/**
*
* @author zhaorong
*/
public class DeleteFile {
public static String deleteFileName = ".svn";
public static String deleteDirectory = "F:/ÏîÄ¿/jalis/svn";
public static void deleteFile(File file) {
if (file.isDirectory()) {
File[] files = file.listFiles();
for (File f : files) {
deleteFile(f);
}
}
System.out.println("delete file: "+file.getPath()+"/"+file.getName());
file.delete();
}
public static void deleteDestFile(File file) {
if (file.isDirectory()) {
if (file.getName().equals(deleteFileName)) {
deleteFile(file);
} else {
File[] files = file.listFiles();
for (File f : files) {
deleteDestFile(f);
}
}
}
}
public static void main(String[] args) {
File file = new File(deleteDirectory);
deleteDestFile(file);
}
}
ɾ³ýǰÎñ±Ø×öºÃ±¸·Ý£¡
Ïà¹ØÎĵµ£º
JavaÔÚJDK1.3Ö®ºó¼ÓÈëÁË¿ÉÐÖú¿ª·¢¶¯Ì¬´úÀí¹¦ÄܵÄAPI.ʹÓö¯Ì¬´úÀí£¬¿ÉÒÔʹһ¸ö´¦ÀíÕߣ¨´úÀí£©·þÎñÓÚ¸÷¸ö¶ÔÏó¡£´´½¨Ò»¸ö¶¯Ì¬´úÀíÀàÖ»ÐèʵÏÖjava.lang.reflect.InvocationHandler½Ó¿Ú¡£
ÏÂÃæ´´½¨Ò»¸ö´¦ÀíÈÕÖ¾µÄ¶¯Ì¬´úÀíÀàLogHandlerÈ¥´úÀíHelloSpeakerÀà
Ê×ÏÈ´´½¨HelloSpeakerµÄ½Ó¿Ú
pa ......
JAVA¿ÉÒÔ˵ÊÇ´ÓC++·¢Õ¹ÆðÀ´µÄÍêÈ«ÃæÏò¶ÔÏóµÄ¿ª·¢ÓïÑÔ,Á½ÕßµÄʵÖÊÇø±ðÊÇÀûÒæ·ÖÊô²»Í¬µÄ¹«Ë¾:SUNºÍ΢Èí.¶Ô´Ë΢Èí·¢²¼ÁË.NETÓëÖ®¿¹ºâ.
´Ó×îеÄVisual Studio .NET 2005¿´,.NETÖ÷ÒªÊÇ4ÖÖÓïÑÔ:VB.NET, C#, C++.NET, J#.
VB.NET¿ÉÒÔ˵ÊÇVB6µÄÉý¼¶,µ«ÎÒÈÏΪVB.NETºÍC#ÒѾÊÇÍêȫȫеÄÓïÑÔÁË,Á½ÕßµÄÄ¿µÄ¶¼ÊÇÒª´ò°ÜJAVAÕâ¸ö¾ºÕ ......
JAVAËÄÖÖ»ù±¾ÅÅÐò,°üÀ¨Ã°ÅÝ·¨,²åÈë·¨,Ñ¡Ôñ·¨,SHELLÅÅÐò·¨.ÆäÖÐÑ¡Ôñ·¨ÊÇðÅÝ·¨µÄ¸Ä½ø,SHELLÅÅÐò·¨ÊÇ ²åÈë·¨µÄ¸Ä½ø.ËùÒÔ´Ó¸ù±¾ÉÏÀ´Ëµ¿ÉÒÔ¹éÄÉΪÁ½ÖÖ²»Í¬µÄÅÅÐò·½·¨:¼´:²åÈë·¨£¦Ã°ÅÝ·¨
Ò» ²åÈë·¨:±éÀúÅÅÐò¼¯ºÏ£¬Ã¿µ½Ò»¸öÔªËØÊ±£¬¶¼Òª½«Õâ¸öÔªËØÓëËùÓÐËü֮ǰµÄÔªËØ±éÀú±È½ÏÒ»±é£¬È÷ûºÏÅÅÐò˳ÐòµÄÔªËØ°¤¸öÒÆ¶¯µ½µ±Ç°·¶Î§ÄÚËü×î ......
×î½ü¿´µ½Ò»¸öÓÐÒâ˼µÄÊ÷Ðνṹ£¬ÎªÃ¿¸ö½ÚµãÌí¼ÓÁËlftºÍrgtÁ½¸öÊôÐÔ¡£ÕâÑù²éÕҸýڵãµÄ×ӽڵ㡢²éÕҸýڵãËùÓи¸½Úµã£¬¾Í²»ÓÃÈ¥µÝ¹é²éѯ£¬Ö»ÐèÒªÓÃbetween¡¢andÓï¾ä¾Í¿ÉÒÔʵÏÖ¡£ÏÂÃæÒÔ´´½¨Ò»¸öÀ¸Ä¿Ê÷ΪÀý£¬ÒÔÏÂÊÇÎÒµÄÀí½â¡£
¡¡¡¡Ò»°ãÀ´½²£¬ÎÒÃÇ´´½¨À¸Ä¿Ê÷µÄʱºò£¬´ó¶àÖ»ÐèÒªÒ»¸öÍâ¼üparentidÀ´Çø·Ö¸Ã½ÚµãÊôÓÚÄĸö¸¸½Úµã¡£Êý ......
¡¡¡¡Í¨³£ÔÚÓÃJAVA¿ª·¢Èí¼þµÄ¹ý³ÌÖУ¬ÎÒÃdz£³£»áÓöµ½ÐèÒª°ÑһЩϵͳµÄÅäÖòÎÊý±£´æµ½Êý¾Ý¿âÖÐÒÔ·ÀÖ¹¶ªÊ§£¬´«Í³µÄ·½·¨Êǽ«Ã¿¸öÅäÖòÎÊý×÷Ϊ¶ÔÏóÀ´½¨Á¢Êý¾Ý¿âÄ£ÐÍ£¬Ï൱ÓÚ°ÑÄ£ÐÍÖеĶÔÏó°ó¶¨µ½Êý¾Ý±íµÄÿ¸ö×Ö¶ÎÉÏ£¬µ«ÕâÑù×öµÄ»°Áé»î¶ÈÌ«µÍ£¬µ±ÐèÒªÌí¼ÓÅäÖòÎÊýʱÏȵÃÍùÊý¾Ý±íÌí¼Ó×ֶΣ¬ÔÙÐÞ¸ÄÊý¾Ý¿âÄ£ÐͺÍÏà¹ØµÄÓ³ÉäÎļþ¡£ÄÜ·ñ ......