Package org.eclipse.viatra.query.runtime.localsearch.matcher.integration

## Class LocalSearchHints

- java.lang.Object
- - org.eclipse.viatra.query.runtime.localsearch.matcher.integration.LocalSearchHints

- All Implemented Interfaces:
    `IMatcherCapability`

      public final class LocalSearchHints
      extends java.lang.Object
      implements IMatcherCapability

  Type safe builder and extractor for Local search specific hints
  Since:
    1.4

- - ### Method Summary

    All Methods Static Methods Instance Methods Concrete Methods
    Modifier and Type | Method | Description
    --- | --- | ---
    `QueryEvaluationHint` | `build()` |
    `QueryEvaluationHint` | `build​(QueryEvaluationHint overridingHint)` |
    `boolean` | `canBeSubstitute​(IMatcherCapability capability)` | Returns true if matchers of this capability can be used as a substitute for a matcher implementing the given capability
    `static LocalSearchHints` | `customizeAdornmentProvider​(IAdornmentProvider adornmentProvider)` |
    `static LocalSearchHints` | `customizeCallDelegationStrategy​(ICallDelegationStrategy strategy)` |
    `static LocalSearchHints` | `customizeCostFunction​(ICostFunction costFunction)` |
    `static LocalSearchHints` | `customizeFlattenCallPredicate​(IFlattenCallPredicate predicate)` |
    `static LocalSearchHints` | `customizeRowCount​(int rowCount)` |
    `static LocalSearchHints` | `customizeTraceCollector​(IRewriterTraceCollector traceCollector)` |
    `static LocalSearchHints` | `customizeUseBase​(boolean useBase)` |
    `IAdornmentProvider` | `getAdornmentProvider()` |
    `ICallDelegationStrategy` | `getCallDelegationStrategy()` |
    `ICostFunction` | `getCostFunction()` |
    `static LocalSearchHints` | `getDefault()` | Default settings which are considered the most safe, providing a reasonable performance for most of the cases.
    `static LocalSearchHints` | `getDefaultFlatten()` | With this setting, the patterns are flattened before planning.
    `static LocalSearchHints` | `getDefaultGeneric()` | Initializes the generic (not EMF specific) search backend with the default settings
    `static LocalSearchHints` | `getDefaultGenericHybrid()` | Initializes the generic (not EMF specific) search backend with hybrid-enabled settings
    `static LocalSearchHints` | `getDefaultHybrid()` | Initializes the default search backend with hybrid-enabled settings
    `static LocalSearchHints` | `getDefaultNoBase()` | Settings to be used when the base index is not available.
    `static LocalSearchHints` | `getDefaultOverriddenBy​(QueryEvaluationHint overridingHint)` | Return the default settings overridden by the given hints
    `IFlattenCallPredicate` | `getFlattenCallPredicate()` |
    `java.lang.Integer` | `getRowCount()` |
    `IRewriterTraceCollector` | `getTraceCollector()` |
    `java.lang.Boolean` | `isConsultSurrogates()` |
    `boolean` | `isUseBase()` |
    `static LocalSearchHints` | `parse​(QueryEvaluationHint hint)` |
    `LocalSearchHints` | `setAdornmentProvider​(IAdornmentProvider adornmentProvider)` |
    `LocalSearchHints` | `setCallDelegationStrategy​(ICallDelegationStrategy callDelegationStrategy)` |
    `LocalSearchHints` | `setConsultSurrogates​(boolean consultSurrogates)` |
    `LocalSearchHints` | `setCostFunction​(ICostFunction costFunction)` |
    `LocalSearchHints` | `setFlattenCallPredicate​(IFlattenCallPredicate flattenCallPredicate)` |
    `LocalSearchHints` | `setRowCount​(int rowCount)` |
    `LocalSearchHints` | `setTraceCollector​(IRewriterTraceCollector traceCollector)` |
    `LocalSearchHints` | `setUseBase​(boolean useBase)` |

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Method Detail

    - #### getDefaultOverriddenBy

          public static LocalSearchHints getDefaultOverriddenBy​(QueryEvaluationHint overridingHint)

      Return the default settings overridden by the given hints

    - #### getDefault

          public static LocalSearchHints getDefault()

      Default settings which are considered the most safe, providing a reasonable performance for most of the cases. Assumes the availability of the base indexer.

    - #### getDefaultFlatten

          public static LocalSearchHints getDefaultFlatten()

      With this setting, the patterns are flattened before planning. This may cause performance gain in some cases compared to the `getDefault()` settings, However this should be used with care for patterns containing calls with several bodies.

    - #### getDefaultNoBase

          public static LocalSearchHints getDefaultNoBase()

      Settings to be used when the base index is not available.

    - #### getDefaultGeneric

          public static LocalSearchHints getDefaultGeneric()

      Initializes the generic (not EMF specific) search backend with the default settings
      Since:
        1.7

    - #### getDefaultHybrid

          public static LocalSearchHints getDefaultHybrid()

      Initializes the default search backend with hybrid-enabled settings
      Since:
        2.1

    - #### getDefaultGenericHybrid

          public static LocalSearchHints getDefaultGenericHybrid()

      Initializes the generic (not EMF specific) search backend with hybrid-enabled settings
      Since:
        2.1

    - #### parse

          public static LocalSearchHints parse​(QueryEvaluationHint hint)

    - #### build

          public QueryEvaluationHint build()

    - #### build

          public QueryEvaluationHint build​(QueryEvaluationHint overridingHint)

      Since:
        1.7

    - #### isConsultSurrogates

          public java.lang.Boolean isConsultSurrogates()

      Since:
        2.9

    - #### isUseBase

          public boolean isUseBase()

    - #### getCostFunction

          public ICostFunction getCostFunction()

    - #### getFlattenCallPredicate

          public IFlattenCallPredicate getFlattenCallPredicate()

    - #### getCallDelegationStrategy

          public ICallDelegationStrategy getCallDelegationStrategy()

      Since:
        2.1

    - #### getRowCount

          public java.lang.Integer getRowCount()

    - #### getAdornmentProvider

          public IAdornmentProvider getAdornmentProvider()

      Since:
        1.5

    - #### getTraceCollector

          public IRewriterTraceCollector getTraceCollector()

      Since:
        1.6

    - #### setConsultSurrogates

          public LocalSearchHints setConsultSurrogates​(boolean consultSurrogates)

      Since:
        2.9

    - #### setUseBase

          public LocalSearchHints setUseBase​(boolean useBase)

    - #### setRowCount

          public LocalSearchHints setRowCount​(int rowCount)

    - #### setCostFunction

          public LocalSearchHints setCostFunction​(ICostFunction costFunction)

    - #### setFlattenCallPredicate

          public LocalSearchHints setFlattenCallPredicate​(IFlattenCallPredicate flattenCallPredicate)

    - #### setCallDelegationStrategy

          public LocalSearchHints setCallDelegationStrategy​(ICallDelegationStrategy callDelegationStrategy)

      Since:
        2.1

    - #### setTraceCollector

          public LocalSearchHints setTraceCollector​(IRewriterTraceCollector traceCollector)

      Since:
        1.6

    - #### setAdornmentProvider

          public LocalSearchHints setAdornmentProvider​(IAdornmentProvider adornmentProvider)

      Since:
        1.5

    - #### customizeUseBase

          public static LocalSearchHints customizeUseBase​(boolean useBase)

    - #### customizeRowCount

          public static LocalSearchHints customizeRowCount​(int rowCount)

    - #### customizeCostFunction

          public static LocalSearchHints customizeCostFunction​(ICostFunction costFunction)

    - #### customizeFlattenCallPredicate

          public static LocalSearchHints customizeFlattenCallPredicate​(IFlattenCallPredicate predicate)

    - #### customizeCallDelegationStrategy

          public static LocalSearchHints customizeCallDelegationStrategy​(ICallDelegationStrategy strategy)

      Since:
        2.1

    - #### customizeAdornmentProvider

          public static LocalSearchHints customizeAdornmentProvider​(IAdornmentProvider adornmentProvider)

      Since:
        1.5

    - #### customizeTraceCollector

          public static LocalSearchHints customizeTraceCollector​(IRewriterTraceCollector traceCollector)

      Since:
        1.6

    - #### canBeSubstitute

          public boolean canBeSubstitute​(IMatcherCapability capability)

      Description copied from interface: `IMatcherCapability`
      Returns true if matchers of this capability can be used as a substitute for a matcher implementing the given capability
      Specified by:
        `canBeSubstitute` in interface `IMatcherCapability`