Class CacheUsageIndirectionPolicy

java.lang.Object
org.eclipse.persistence.config.CacheUsageIndirectionPolicy

public class CacheUsageIndirectionPolicy extends Object
In-memory querying and conforming indirection policy. The class contains all the valid values for QueryHints.INDIRECTION_POLICY query hint. This can be used on a query with a CACHE_USAGE hint to configure the behavior of in-memory querying and conforming's treatment of uninstantiated indirection/lazy relationships. This is only relevant when the query traverses a join across a lazy relationship. JPA Query Hint Usage:

query.setHint(QueryHints.INDIRECTION_POLICY, CacheUsageIndirectionPolicy.Trigger);

or

@QueryHint(name=QueryHints.INDIRECTION_POLICY, value=CacheUsageIndirectionPolicy.Trigger)

Hint values are case-insensitive. "" could be used instead of default value CacheUsageIndirectionPolicy.Exception.

See Also:
Author:
James Sutherland
  • Field Details

    • Exception

      public static final String Exception
      If conforming encounters an uninstantiated indirection/lazy object an exception is thrown.
      See Also:
    • Trigger

      public static final String Trigger
      If conforming encounters an uninstantiated indirection/lazy object it is triggered.
      See Also:
    • Conform

      public static final String Conform
      If conforming encounters an uninstantiated indirection/lazy object it is assumed to conform.
      See Also:
    • NotConform

      public static final String NotConform
      If conforming encounters an uninstantiated indirection/lazy object it is assumed to not conform.
      See Also:
    • DEFAULT

      public static final String DEFAULT
      The default type is Exception.
      See Also:
  • Constructor Details

    • CacheUsageIndirectionPolicy

      public CacheUsageIndirectionPolicy()