Package org.hibernate.dialect
Enum GroupByConstantRenderingStrategy
- java.lang.Object
-
- java.lang.Enum<GroupByConstantRenderingStrategy>
-
- org.hibernate.dialect.GroupByConstantRenderingStrategy
-
- All Implemented Interfaces:
Serializable
,Comparable<GroupByConstantRenderingStrategy>
public enum GroupByConstantRenderingStrategy extends Enum<GroupByConstantRenderingStrategy>
Strategies for rendering a constant in a group by.
-
-
Enum Constant Summary
Enum Constants Enum Constant Description COLUMN_REFERENCE
Renders a column reference to a dummy table e.g.CONSTANT
Renders a constant e.g.CONSTANT_EXPRESSION
Renders a constant expression e.g.EMPTY_GROUPING
The strategy for ANSI SQL compliant DBs like e.g.SUBQUERY
Renders a subquery e.g.
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static GroupByConstantRenderingStrategy
valueOf(String name)
Returns the enum constant of this type with the specified name.static GroupByConstantRenderingStrategy[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
EMPTY_GROUPING
public static final GroupByConstantRenderingStrategy EMPTY_GROUPING
The strategy for ANSI SQL compliant DBs like e.g. PostgreSQL that renders `()` i.e. the empty grouping.
-
CONSTANT
public static final GroupByConstantRenderingStrategy CONSTANT
Renders a constant e.g. `'0'`
-
CONSTANT_EXPRESSION
public static final GroupByConstantRenderingStrategy CONSTANT_EXPRESSION
Renders a constant expression e.g. `'0' || '0'`
-
SUBQUERY
public static final GroupByConstantRenderingStrategy SUBQUERY
Renders a subquery e.g. `(select 1)`
-
COLUMN_REFERENCE
public static final GroupByConstantRenderingStrategy COLUMN_REFERENCE
Renders a column reference to a dummy table e.g. `, (select 1 x) dummy` and `dummy.x`
-
-
Method Detail
-
values
public static GroupByConstantRenderingStrategy[] 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 (GroupByConstantRenderingStrategy c : GroupByConstantRenderingStrategy.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static GroupByConstantRenderingStrategy 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
-
-