Пример #1
0
 /// <summary>
 /// Constructs a new instance of the <see cref="CrawlWave.ServerPlugins.Initializer.InitializerPlugin"/> class.
 /// </summary>
 public InitializerPlugin()
 {
     dataDependent = true;
     description = "CrawlWave Initializer Plugin";
     enabled = true;
     host = null;
     name = "CrawlWave.ServerPlugins.Initializer";
     percent = 0;
     settingsPath = String.Empty;
     state = PluginState.Stopped;
     version = Assembly.GetExecutingAssembly().GetName().Version.ToString();
     settings = PluginSettings.Instance();
     pluginThreads = null;
     outputStream = null;
     urlsToVisit = new Queue();
     mustStop = false;
     runningThreads = 0;
     totalDomains = 0;
     processedDomains = 0;
     banned = BannedHostsCache.Instance();
     dbcon = null;
     urlcmd = null;
     hostcmd = null;
     sync = new object();
 }
Пример #2
0
 /// <summary>
 /// Constructs a new instance of the Plugin's settings form.
 /// </summary>
 public frmPluginSettings()
 {
     //
     // Required for Windows Form Designer support
     //
     InitializeComponent();
     settings = PluginSettings.Instance();
 }
Пример #3
0
 /// <summary>
 /// Provides a global access point for the single instance of the <see cref="PluginSettings"/>
 /// class.
 /// </summary>
 /// <returns>A reference to the single instance of <see cref="PluginSettings"/>.</returns>
 public static PluginSettings Instance()
 {
     if (instance==null)
     {
         lock(typeof(PluginSettings))
         {
             if( instance == null )
             {
                 instance = new PluginSettings();
             }
         }
     }
     return instance;
 }