
Class SearchParamRegistryImpl
java.lang.Object
ca.uhn.fhir.jpa.searchparam.registry.SearchParamRegistryImpl
- All Implemented Interfaces:
IResourceChangeListener,ISearchParamRegistryController,ca.uhn.fhir.rest.server.util.IResourceRepositoryCache,ca.uhn.fhir.rest.server.util.ISearchParamRegistry
public class SearchParamRegistryImpl
extends Object
implements ca.uhn.fhir.rest.server.util.ISearchParamRegistry, IResourceChangeListener, ISearchParamRegistryController
-
Nested Class Summary
Nested classes/interfaces inherited from interface ca.uhn.fhir.rest.server.util.ISearchParamRegistry
ca.uhn.fhir.rest.server.util.ISearchParamRegistry.SearchParamLookupContextEnum -
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidOptional<ca.uhn.fhir.context.RuntimeSearchParam> getActiveComboSearchParamById(String theResourceName, org.hl7.fhir.instance.model.api.IIdType theId) List<ca.uhn.fhir.context.RuntimeSearchParam> getActiveComboSearchParams(String theResourceName, ca.uhn.fhir.context.ComboSearchParamType theParamType, ca.uhn.fhir.rest.server.util.ISearchParamRegistry.SearchParamLookupContextEnum theContext) List<ca.uhn.fhir.context.RuntimeSearchParam> getActiveComboSearchParams(String theResourceName, ca.uhn.fhir.rest.server.util.ISearchParamRegistry.SearchParamLookupContextEnum theContext) List<ca.uhn.fhir.context.RuntimeSearchParam> getActiveComboSearchParams(String theResourceName, Set<String> theParamNames, ca.uhn.fhir.rest.server.util.ISearchParamRegistry.SearchParamLookupContextEnum theContext) ca.uhn.fhir.context.RuntimeSearchParamgetActiveSearchParam(String theResourceName, String theParamName, ca.uhn.fhir.rest.server.util.ISearchParamRegistry.SearchParamLookupContextEnum theContext) ca.uhn.fhir.context.RuntimeSearchParamgetActiveSearchParamByUrl(String theUrl, ca.uhn.fhir.rest.server.util.ISearchParamRegistry.SearchParamLookupContextEnum theContext) ca.uhn.fhir.rest.server.util.ResourceSearchParamsgetActiveSearchParams(String theResourceName, ca.uhn.fhir.rest.server.util.ISearchParamRegistry.SearchParamLookupContextEnum theContext) voidhandleChange(IResourceChangeEvent theResourceChangeEvent) Called by theIResourceChangeListenerRegistrywhen matching resource changes are detectedvoidhandleInit(Collection<org.hl7.fhir.instance.model.api.IIdType> theResourceIds) This method is called withinResourceChangeListenerCacheRefresherImpl.LOCAL_REFRESH_INTERVAL_MSof a listener registrationbooleanvoidThere is a circular reference between this class and the ResourceChangeListenerRegistry: SearchParamRegistryImpl -> ResourceChangeListenerRegistry -> InMemoryResourceMatcher -> SearchParamRegistryImpl.voidvoidvoidsetActiveSearchParams(RuntimeSearchParamCache theSearchParams) voidsetFhirContext(ca.uhn.fhir.context.FhirContext theFhirContext) voidsetInterceptorServiceForUnitTest(ca.uhn.fhir.interceptor.api.IInterceptorService theInterceptorService) voidsetPartitionSettingsForUnitTest(PartitionSettings thePartitionSettings) voidsetPhoneticEncoder(ca.uhn.fhir.context.phonetic.IPhoneticEncoder thePhoneticEncoder) All SearchParameters with the name "phonetic" encode the normalized index value using this phonetic encoder.voidsetPopulateSearchParamIdentities(boolean myPrePopulateSearchParamIdentities) voidsetResourceChangeListenerRegistry(IResourceChangeListenerRegistry theResourceChangeListenerRegistry) voidsetSearchParameterCanonicalizerForUnitTest(SearchParameterCanonicalizer theSearchParameterCanonicalizerForUnitTest) voidsetStorageSettings(StorageSettings theStorageSettings) voidstart()voidMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface ca.uhn.fhir.rest.server.util.ISearchParamRegistry
getActiveSearchParam, getActiveSearchParams, getRuntimeSearchParam, getRuntimeSearchParams, getValidSearchParameterNamesIncludingMeta, hasActiveSearchParam
-
Field Details
-
NON_DISABLEABLE_SEARCH_PARAMS
-
MAX_MANAGED_PARAM_COUNT
- See Also:
-
PARAM_LANGUAGE_ID
- See Also:
-
PARAM_LANGUAGE_DESCRIPTION
- See Also:
-
PARAM_LANGUAGE_PATH
- See Also:
-
PARAM_TEXT_DESCRIPTION
- See Also:
-
PARAM_CONTENT_DESCRIPTION
- See Also:
-
-
Constructor Details
-
SearchParamRegistryImpl
public SearchParamRegistryImpl()Constructor
-
-
Method Details
-
setPopulateSearchParamIdentities
-
setPartitionSettingsForUnitTest
-
start
-
getActiveSearchParam
public ca.uhn.fhir.context.RuntimeSearchParam getActiveSearchParam(@Nonnull String theResourceName, @Nonnull String theParamName, @Nonnull ca.uhn.fhir.rest.server.util.ISearchParamRegistry.SearchParamLookupContextEnum theContext) - Specified by:
getActiveSearchParamin interfaceca.uhn.fhir.rest.server.util.ISearchParamRegistry
-
getActiveSearchParams
@Nonnull public ca.uhn.fhir.rest.server.util.ResourceSearchParams getActiveSearchParams(@Nonnull String theResourceName, @Nonnull ca.uhn.fhir.rest.server.util.ISearchParamRegistry.SearchParamLookupContextEnum theContext) - Specified by:
getActiveSearchParamsin interfaceca.uhn.fhir.rest.server.util.ISearchParamRegistry
-
getActiveComboSearchParams
public List<ca.uhn.fhir.context.RuntimeSearchParam> getActiveComboSearchParams(@Nonnull String theResourceName, @Nonnull ca.uhn.fhir.rest.server.util.ISearchParamRegistry.SearchParamLookupContextEnum theContext) - Specified by:
getActiveComboSearchParamsin interfaceca.uhn.fhir.rest.server.util.ISearchParamRegistry
-
getActiveComboSearchParams
public List<ca.uhn.fhir.context.RuntimeSearchParam> getActiveComboSearchParams(@Nonnull String theResourceName, @Nonnull ca.uhn.fhir.context.ComboSearchParamType theParamType, @Nonnull ca.uhn.fhir.rest.server.util.ISearchParamRegistry.SearchParamLookupContextEnum theContext) - Specified by:
getActiveComboSearchParamsin interfaceca.uhn.fhir.rest.server.util.ISearchParamRegistry
-
getActiveComboSearchParams
public List<ca.uhn.fhir.context.RuntimeSearchParam> getActiveComboSearchParams(@Nonnull String theResourceName, @Nonnull Set<String> theParamNames, @Nonnull ca.uhn.fhir.rest.server.util.ISearchParamRegistry.SearchParamLookupContextEnum theContext) - Specified by:
getActiveComboSearchParamsin interfaceca.uhn.fhir.rest.server.util.ISearchParamRegistry
-
getActiveSearchParamByUrl
@Nullable public ca.uhn.fhir.context.RuntimeSearchParam getActiveSearchParamByUrl(@Nonnull String theUrl, @Nonnull ca.uhn.fhir.rest.server.util.ISearchParamRegistry.SearchParamLookupContextEnum theContext) - Specified by:
getActiveSearchParamByUrlin interfaceca.uhn.fhir.rest.server.util.ISearchParamRegistry
-
getActiveComboSearchParamById
public Optional<ca.uhn.fhir.context.RuntimeSearchParam> getActiveComboSearchParamById(@Nonnull String theResourceName, @Nonnull org.hl7.fhir.instance.model.api.IIdType theId) - Specified by:
getActiveComboSearchParamByIdin interfaceca.uhn.fhir.rest.server.util.ISearchParamRegistry
-
getHashIdentityToIndexedSearchParamMap
public Map<Long,ca.uhn.fhir.rest.server.util.IndexedSearchParam> getHashIdentityToIndexedSearchParamMap() -
setFhirContext
-
setStorageSettings
-
requestRefresh
- Specified by:
requestRefreshin interfaceca.uhn.fhir.rest.server.util.IResourceRepositoryCache
-
forceRefresh
- Specified by:
forceRefreshin interfaceca.uhn.fhir.rest.server.util.IResourceRepositoryCache
-
refreshCacheIfNecessary
- Specified by:
refreshCacheIfNecessaryin interfaceISearchParamRegistryController
-
setResourceChangeListenerRegistry
public void setResourceChangeListenerRegistry(IResourceChangeListenerRegistry theResourceChangeListenerRegistry) -
registerListener
There is a circular reference between this class and the ResourceChangeListenerRegistry: SearchParamRegistryImpl -> ResourceChangeListenerRegistry -> InMemoryResourceMatcher -> SearchParamRegistryImpl. Since we only need this once on boot-up, we delay until ContextRefreshedEvent. -
unregisterListener
-
getActiveSearchParams
-
setActiveSearchParams
-
setPhoneticEncoder
All SearchParameters with the name "phonetic" encode the normalized index value using this phonetic encoder.- Specified by:
setPhoneticEncoderin interfaceca.uhn.fhir.rest.server.util.ISearchParamRegistry- Since:
- 5.1.0
-
handleChange
Description copied from interface:IResourceChangeListenerCalled by theIResourceChangeListenerRegistrywhen matching resource changes are detected- Specified by:
handleChangein interfaceIResourceChangeListener
-
handleInit
Description copied from interface:IResourceChangeListenerThis method is called withinResourceChangeListenerCacheRefresherImpl.LOCAL_REFRESH_INTERVAL_MSof a listener registration- Specified by:
handleInitin interfaceIResourceChangeListener- Parameters:
theResourceIds- the ids of all resources that match the search parameters the listener was registered with
-
isInitialized
- Specified by:
isInitializedin interfaceca.uhn.fhir.rest.server.util.ISearchParamRegistry
-
resetForUnitTest
-
setSearchParameterCanonicalizerForUnitTest
public void setSearchParameterCanonicalizerForUnitTest(SearchParameterCanonicalizer theSearchParameterCanonicalizerForUnitTest) -
setInterceptorServiceForUnitTest
public void setInterceptorServiceForUnitTest(ca.uhn.fhir.interceptor.api.IInterceptorService theInterceptorService)
-