
Class ResourceIndexedSearchParams
java.lang.Object
ca.uhn.fhir.jpa.searchparam.extractor.ResourceIndexedSearchParams
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic ResourceIndexedSearchParamsempty()Create an empty and immutable structure.extractCompositeStringUniquesValueChains(String theResourceType, List<List<String>> thePartsChoices) This method is used to create a set of all possible combinations of parameters across a set of search parameters.voidfindMissingSearchParams(PartitionSettings thePartitionSettings, StorageSettings theStorageSettings, ResourceTable theEntity, ca.uhn.fhir.rest.server.util.ResourceSearchParams theActiveSearchParams) static booleanisMatchSearchParam(StorageSettings theStorageSettings, String theResourceName, String theParamName, BaseResourceIndexedSearchParam theIndexedSearchParam) booleanmatchParam(StorageSettings theStorageSettings, String theResourceName, String theParamName, ca.uhn.fhir.context.RuntimeSearchParam theParamDef, ca.uhn.fhir.model.api.IQueryParameterType theValue) booleanmatchResourceLinks(StorageSettings theStorageSettings, String theResourceName, String theParamName, ca.uhn.fhir.model.api.IQueryParameterType theParam, String theParamPath) booleanmatchResourceLinks(StorageSettings theStorageSettings, String theResourceName, String theParamName, ca.uhn.fhir.model.api.IQueryParameterType theParam, List<String> theParamPaths) booleanmatchResourceLinks(String theResourceName, String theParamName, ca.uhn.fhir.model.api.IQueryParameterType theParam, String theParamPath) Deprecated.Replace with the method belowvoidvoidtoString()voidupdateSpnamePrefixForIndexOnUpliftedChain(String theContainingType, String theSpnamePrefix) voidupdateSpnamePrefixForLinksOnContainedResource(String theSpNamePrefix) static ResourceIndexedSearchParamswithLists(ResourceTable theResourceTable) Create a new instance that holds all the existing indexes in lists so that any duplicates are preserved.static ResourceIndexedSearchParamswithSets()Create a new instance that uses Sets as the internal collection type in order to defend against duplicates.
-
Field Details
-
myStringParams
-
myTokenParams
-
myNumberParams
-
myQuantityParams
-
myQuantityNormalizedParams
-
myDateParams
-
myUriParams
-
myCoordsParams
-
myComboStringUniques
-
myComboTokenNonUnique
-
myLinks
-
mySearchParamPresentEntities
-
myCompositeParams
-
myPopulatedResourceLinkParameters
-
-
Constructor Details
-
ResourceIndexedSearchParams
Deprecated.Use a factory constructor insteadTODO: Remove this - Currently used by CDR though
-
-
Method Details
-
getResourceLinks
-
populateResourceTableSearchParamsPresentFlags
-
populateResourceTableParamCollections
-
updateSpnamePrefixForIndexOnUpliftedChain
public void updateSpnamePrefixForIndexOnUpliftedChain(String theContainingType, String theSpnamePrefix) -
updateSpnamePrefixForLinksOnContainedResource
-
getPopulatedResourceLinkParameters
-
matchParam
public boolean matchParam(StorageSettings theStorageSettings, String theResourceName, String theParamName, ca.uhn.fhir.context.RuntimeSearchParam theParamDef, ca.uhn.fhir.model.api.IQueryParameterType theValue) -
isMatchSearchParam
public static boolean isMatchSearchParam(StorageSettings theStorageSettings, String theResourceName, String theParamName, BaseResourceIndexedSearchParam theIndexedSearchParam) -
matchResourceLinks
@Deprecated public boolean matchResourceLinks(String theResourceName, String theParamName, ca.uhn.fhir.model.api.IQueryParameterType theParam, String theParamPath) Deprecated.Replace with the method below -
matchResourceLinks
public boolean matchResourceLinks(StorageSettings theStorageSettings, String theResourceName, String theParamName, ca.uhn.fhir.model.api.IQueryParameterType theParam, List<String> theParamPaths) -
matchResourceLinks
public boolean matchResourceLinks(StorageSettings theStorageSettings, String theResourceName, String theParamName, ca.uhn.fhir.model.api.IQueryParameterType theParam, String theParamPath) -
toString
-
findMissingSearchParams
public void findMissingSearchParams(PartitionSettings thePartitionSettings, StorageSettings theStorageSettings, ResourceTable theEntity, ca.uhn.fhir.rest.server.util.ResourceSearchParams theActiveSearchParams) -
extractCompositeStringUniquesValueChains
public static Set<String> extractCompositeStringUniquesValueChains(String theResourceType, List<List<String>> thePartsChoices) This method is used to create a set of all possible combinations of parameters across a set of search parameters. An example of why this is needed:Let's say we have a unique index on (Patient:gender AND Patient:name). Then we pass in
SMITH, Johnwith a gender ofmale.In this case, because the name parameter matches both first and last name, we now need two unique indexes:
- Patient?gender=male&name=SMITH
- Patient?gender=male&name=JOHN
So this recursive algorithm calculates those
- Parameters:
theResourceType- E.g.PatientthePartsChoices- E.g.[[gender=male], [name=SMITH, name=JOHN]]
-
withSets
Create a new instance that uses Sets as the internal collection type in order to defend against duplicates. This should be used when calculating the set of indexes for a resource that is about to be stored. -
empty
Create an empty and immutable structure. -
withLists
Create a new instance that holds all the existing indexes in lists so that any duplicates are preserved.
-