diff transform/TransformFactory.h @ 477:e0784311a103

* Start thread to populate uninstalled transforms only on request (so runner doesn't have to have it)
author Chris Cannam
date Tue, 11 Nov 2008 09:41:45 +0000
parents a70dcfed59c1
children f933062a7f80
line wrap: on
line diff
--- a/transform/TransformFactory.h	Fri Nov 07 20:25:57 2008 +0000
+++ b/transform/TransformFactory.h	Tue Nov 11 09:41:45 2008 +0000
@@ -40,6 +40,18 @@
 
     static TransformFactory *getInstance();
 
+    /**
+     * TransformFactory has a background thread that can populate
+     * uninstalled transforms from network RDF resources.  It is not
+     * started by default, but it's a good idea to start it when the
+     * program starts up, if the uninstalled transforms may be of use
+     * later; otherwise there will be a bottleneck the first time
+     * they're requested.
+     *
+     * If this thread is not already running, start it now.
+     */
+    void startPopulationThread();
+
     TransformList getAllTransformDescriptions();
     TransformDescription getTransformDescription(TransformId id);
 
@@ -212,6 +224,8 @@
         TransformFactory *m_factory;
     };
 
+    UninstalledTransformsPopulateThread *m_thread;
+
     static TransformFactory *m_instance;
 };