SrvStateManager implementation that owns the per-database SearchContext registry.
Both the GUI (org.) and the stand-alone HTTP server
(JabRefSrvStateManager) keep one SearchContext per open library, keyed by
BibDatabaseContext#getUid(). They only differ in when a context is registered:
the GUI registers one lazily when a library tab opens, the server registers all of
them up front in its constructor. The lookup itself and the "must be registered
before the database is served" invariant are identical, so they live here.
| Modifier and Type | Field and Description |
|---|---|
| private static final Logger | |
| private final Map |
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| public SearchContext | getSearchContext(BibDatabaseContext database)
Implements org. Returns the |
| public void | removeSearchContext(BibDatabaseContext database)
Removes the |
| public void | setSearchContext(BibDatabaseContext database, SearchContext searchContext)
Registers the |
| LOGGER | back to summary |
|---|---|
| private static final Logger LOGGER | |
| searchContexts | back to summary |
|---|---|
| private final Map<String, SearchContext> searchContexts | |
| AbstractSrvStateManager | back to summary |
|---|---|
| public AbstractSrvStateManager() | |
| getSearchContext | back to summary |
|---|---|
| public SearchContext getSearchContext(BibDatabaseContext database) Implements org. Doc from org. Returns the
| |
| removeSearchContext | back to summary |
|---|---|
| public void removeSearchContext(BibDatabaseContext database) Removes the | |
| setSearchContext | back to summary |
|---|---|
| public void setSearchContext(BibDatabaseContext database, SearchContext searchContext) Registers the | |