waitForGeneration
Waits for the target generation to become visible in the searcher. If the current searcher is older than the target generation, this method will block until the searcher is reopened, by another via ReferenceManager.maybeRefresh or until the ReferenceManager is closed.
Parameters
the generation to wait for
Waits for the target generation to become visible in the searcher, up to a maximum specified milli-seconds. If the current searcher is older than the target generation, this method will block until the searcher has been reopened by another thread via ReferenceManager.maybeRefresh, the given waiting time has elapsed, or until the ReferenceManager is closed.
NOTE: if the waiting time elapses before the requested target generation is available the current [SearcherManager] is returned instead.
Return
true if the targetGeneration is now available, or false if maxMS wait time was exceeded
Parameters
the generation to wait for
maximum milliseconds to wait, or -1 to wait indefinitely