Package ca.uhn.fhir.jpa.dao.index
Class DaoResourceLinkResolver
java.lang.Object
ca.uhn.fhir.jpa.dao.index.DaoResourceLinkResolver
- All Implemented Interfaces:
IResourceLinkResolver
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription<T extends org.hl7.fhir.instance.model.api.IBaseResource>
Optional<ResourceTable>createPlaceholderTargetIfConfiguredToDoSo
(Class<T> theType, org.hl7.fhir.instance.model.api.IBaseReference theReference, String theIdToAssignToPlaceholder, ca.uhn.fhir.rest.api.server.RequestDetails theRequest, ca.uhn.fhir.rest.api.server.storage.TransactionDetails theTransactionDetails) protected ca.uhn.fhir.mdm.util.CanonicalIdentifier
extractIdentifierFromUrl
(String theValue) Extracts the first available identifier from the URL partfindTargetResource
(ca.uhn.fhir.interceptor.model.RequestPartitionId theRequestPartitionId, ca.uhn.fhir.context.RuntimeSearchParam theSearchParam, String theSourcePath, org.hl7.fhir.instance.model.api.IIdType theSourceResourceId, String theResourceType, Class<? extends org.hl7.fhir.instance.model.api.IBaseResource> theType, org.hl7.fhir.instance.model.api.IBaseReference theReference, ca.uhn.fhir.rest.api.server.RequestDetails theRequest, ca.uhn.fhir.rest.api.server.storage.TransactionDetails theTransactionDetails) void
validateTypeOrThrowException
(Class<? extends org.hl7.fhir.instance.model.api.IBaseResource> theType)
-
Field Details
-
myEntityManager
-
-
Constructor Details
-
DaoResourceLinkResolver
public DaoResourceLinkResolver()
-
-
Method Details
-
findTargetResource
public IResourceLookup findTargetResource(@Nonnull ca.uhn.fhir.interceptor.model.RequestPartitionId theRequestPartitionId, ca.uhn.fhir.context.RuntimeSearchParam theSearchParam, String theSourcePath, org.hl7.fhir.instance.model.api.IIdType theSourceResourceId, String theResourceType, Class<? extends org.hl7.fhir.instance.model.api.IBaseResource> theType, org.hl7.fhir.instance.model.api.IBaseReference theReference, ca.uhn.fhir.rest.api.server.RequestDetails theRequest, ca.uhn.fhir.rest.api.server.storage.TransactionDetails theTransactionDetails) - Specified by:
findTargetResource
in interfaceIResourceLinkResolver
-
createPlaceholderTargetIfConfiguredToDoSo
public <T extends org.hl7.fhir.instance.model.api.IBaseResource> Optional<ResourceTable> createPlaceholderTargetIfConfiguredToDoSo(Class<T> theType, org.hl7.fhir.instance.model.api.IBaseReference theReference, @Nullable String theIdToAssignToPlaceholder, ca.uhn.fhir.rest.api.server.RequestDetails theRequest, ca.uhn.fhir.rest.api.server.storage.TransactionDetails theTransactionDetails) - Parameters:
theIdToAssignToPlaceholder
- If specified, the placeholder resource created will be given a specific ID
-
extractIdentifierFromUrl
Extracts the first available identifier from the URL part- Parameters:
theValue
- Part of the URL to extract identifiers from- Returns:
- Returns the first available identifier in the canonical form or null if URL contains no identifier param
- Throws:
IllegalArgumentException
- IllegalArgumentException is thrown in case identifier parameter can not be split usingsystem|value
pattern.
-
validateTypeOrThrowException
public void validateTypeOrThrowException(Class<? extends org.hl7.fhir.instance.model.api.IBaseResource> theType) - Specified by:
validateTypeOrThrowException
in interfaceIResourceLinkResolver
-