Package org.hibernate.sql.results.spi
Enum ListResultsConsumer.UniqueSemantic
- java.lang.Object
-
- java.lang.Enum<ListResultsConsumer.UniqueSemantic>
-
- org.hibernate.sql.results.spi.ListResultsConsumer.UniqueSemantic
-
- All Implemented Interfaces:
Serializable
,Comparable<ListResultsConsumer.UniqueSemantic>
- Enclosing class:
- ListResultsConsumer<R>
public static enum ListResultsConsumer.UniqueSemantic extends Enum<ListResultsConsumer.UniqueSemantic>
Ways this consumer can handle in-memory row de-duplication
-
-
Enum Constant Summary
Enum Constants Enum Constant Description ALLOW
De-duplication is allowed if the query and result type allowASSERT
Apply in-memory duplication checks, throwing a HibernateException when duplicates are foundFILTER
Apply in-memory de-duplication, removing rows already part of the resultsNEVER
Never apply unique handling.NONE
Apply no in-memory de-duplication
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static ListResultsConsumer.UniqueSemantic
valueOf(String name)
Returns the enum constant of this type with the specified name.static ListResultsConsumer.UniqueSemantic[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
NONE
public static final ListResultsConsumer.UniqueSemantic NONE
Apply no in-memory de-duplication
-
FILTER
public static final ListResultsConsumer.UniqueSemantic FILTER
Apply in-memory de-duplication, removing rows already part of the results
-
ASSERT
public static final ListResultsConsumer.UniqueSemantic ASSERT
Apply in-memory duplication checks, throwing a HibernateException when duplicates are found
-
NEVER
public static final ListResultsConsumer.UniqueSemantic NEVER
Never apply unique handling. E.g. for NativeQuery. WhereasNONE
can be adjusted, NEVER will never apply unique handling
-
ALLOW
public static final ListResultsConsumer.UniqueSemantic ALLOW
De-duplication is allowed if the query and result type allow
-
-
Method Detail
-
values
public static ListResultsConsumer.UniqueSemantic[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (ListResultsConsumer.UniqueSemantic c : ListResultsConsumer.UniqueSemantic.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static ListResultsConsumer.UniqueSemantic valueOf(String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is null
-
-