Interface ContentExpression

  • All Superinterfaces:
    Expression, OrderableExpression, ScalarExpression

    public interface ContentExpression
    extends ScalarExpression
    An expression for searching on any indexed content.

    The ContentExpression lets you build a a predicate that searches in all indexed content in the iKnowBase data store, based on the metadata definitions of attributes.

    The ContentExpression cannot be used as a select-expression, nor for ordering.

    Example

     query1 = factory.builder().where(contentExpression().exact("Find this exact phrase").build();
     query2 = factory.builder().where(contentExpression().any("noreg", "norge", "norway").build();
     query3 = factory.builder().where(contentExpression().all("liverpool", "leeds").build();
     
    • Method Detail

      • exact

        Predicate exact​(String phrase)
        Creates a a predicate searching for an exact phrase.
        Parameters:
        phrase - phrase to search for
        Returns:
        a new Predicate
      • any

        Predicate any​(String... words)
        Creates a predicate searching for any of the specified words.
        Parameters:
        words - words to search for
        Returns:
        a new Predicate
      • all

        Predicate all​(String... words)
        Creates a predicate searching for all of the specified words.
        Parameters:
        words - words to search for
        Returns:
        a new Predicate