Author: j16sdiz
Date: 2009-01-04 07:31:55 +0000 (Sun, 04 Jan 2009)
New Revision: 24906

Modified:
   trunk/plugins/XMLSpider/XMLSpider.java
Log:
start some request in lower priority

Modified: trunk/plugins/XMLSpider/XMLSpider.java
===================================================================
--- trunk/plugins/XMLSpider/XMLSpider.java      2009-01-04 07:27:15 UTC (rev 
24905)
+++ trunk/plugins/XMLSpider/XMLSpider.java      2009-01-04 07:31:55 UTC (rev 
24906)
@@ -332,6 +332,15 @@
                }
        }
 
+       protected class StartSomeRequestsCallback implements Runnable {
+               StartSomeRequestsCallback() {
+               }
+
+               public void run() {
+                       startSomeRequests();
+               }
+       }
+
        protected static class CallbackPrioritizer implements 
Comparator<Runnable> {
                public int compare(Runnable o1, Runnable o2) {
                        if (o1.getClass() == o2.getClass())
@@ -349,6 +358,8 @@
                                return 2;
                        else if (r instanceof SetConfigCallback)
                                return 3;
+                       else if (r instanceof StartSomeRequestsCallback)
+                               return 4;
 
                        return -1;
                }
@@ -552,7 +563,7 @@
                for (int i = 0; i < initialURIs.length; i++)
                        queueURI(initialURIs[i], "bookmark", false);
 
-               startSomeRequests();
+               callbackExecutor.execute(new StartSomeRequestsCallback());
        }
 
        private WebInterface webInterface;

_______________________________________________
cvs mailing list
[email protected]
http://emu.freenetproject.org/cgi-bin/mailman/listinfo/cvs

Reply via email to