Interface DocumentBuilderHelper

  • All Known Implementing Classes:
    DefaultDocumentBuilderHelper

    public interface DocumentBuilderHelper
    Helper methods used to support building the document for indexing.
    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      Object readValueByPath​(com.jayway.jsonpath.DocumentContext context, com.broadleafcommerce.search.api.domain.FieldDefinition field)
      Read the value of the field from the given context object.
      Object readValueByPath​(com.jayway.jsonpath.DocumentContext context, String path)
      Read the value at the path on the given context object.
    • Method Detail

      • readValueByPath

        @Nullable
        Object readValueByPath​(com.jayway.jsonpath.DocumentContext context,
                               com.broadleafcommerce.search.api.domain.FieldDefinition field)
        Read the value of the field from the given context object.
        Parameters:
        context - the object to read from
        field - the field to read the value of
        Returns:
        the value of the field on the object, or null if not found
      • readValueByPath

        @Nullable
        Object readValueByPath​(com.jayway.jsonpath.DocumentContext context,
                               @Nullable
                               String path)
        Read the value at the path on the given context object.
        Parameters:
        context - the object to read from
        path - the path to read the value at
        Returns:
        the value at the path on the object, or null if not found