/// ------------------------------------------------------------------------------------ /// <summary> /// Forcibly ends the task of finding servers begun by BeginFindServers without waiting /// for it to complete normally. /// </summary> /// ------------------------------------------------------------------------------------ public void ForceEndFindServers() { if (m_serverFinder != null) { m_serverFinder.ForceStop(); m_serverFinder = null; } }
/// ------------------------------------------------------------------------------------ /// <summary> /// Used to populate the File Open dialog, this returns the names of the remote servers /// on which the user might be able to open projects. The local server may be the only one, /// and always will be if a client-server backend is not configured. /// </summary> /// <param name="foundServer">Callback that is invoked when a server is found /// (string parameter is the IP address of the found server).</param> /// ------------------------------------------------------------------------------------ public void BeginFindServers(Action<string> foundServer) { if (m_serverFinder != null && !m_serverFinder.IsCompleted) throw new InvalidOperationException("Can not start a new find servers before the previous one finishes."); m_serverFinder = new Db4OServerFinder(foundServer); }