Class HSearchElementCache

java.lang.Object
ca.uhn.fhir.jpa.model.search.HSearchElementCache

public class HSearchElementCache extends Object
Provide a lookup of created Hibernate Search DocumentElement entries. The Hibernate Search DocumentElement api only supports create - it does not support fetching an existing element. This class demand-creates object elements for a given path.
  • Constructor Summary

    Constructors
    Constructor
    Description
    HSearchElementCache(org.hibernate.search.engine.backend.document.DocumentElement theRoot)
    Create the helper rooted on the given DocumentElement
  • Method Summary

    Modifier and Type
    Method
    Description
    org.hibernate.search.engine.backend.document.DocumentElement
    Fetch or create an Object DocumentElement with thePath from the root element.
    org.hibernate.search.engine.backend.document.DocumentElement
    Fetch or create an Object DocumentElement with thePath from the root element.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • HSearchElementCache

      public HSearchElementCache(org.hibernate.search.engine.backend.document.DocumentElement theRoot)
      Create the helper rooted on the given DocumentElement
      Parameters:
      theRoot - the document root
  • Method Details

    • getObjectElement

      public org.hibernate.search.engine.backend.document.DocumentElement getObjectElement(@Nonnull String... thePath)
      Fetch or create an Object DocumentElement with thePath from the root element.
      Parameters:
      thePath - the property names of the object path. E.g. "sp","code","token"
      Returns:
      the existing or created element
    • getObjectElement

      public org.hibernate.search.engine.backend.document.DocumentElement getObjectElement(@Nonnull List<String> thePath)
      Fetch or create an Object DocumentElement with thePath from the root element.
      Parameters:
      thePath - the property names of the object path. E.g. "sp","code","token"
      Returns:
      the existing or created element