Enum DefaultNameStrategy
- All Implemented Interfaces:
StatementNameStrategy,Serializable,Comparable<DefaultNameStrategy>,java.lang.constant.Constable
Default strategies which build a basis of more complex strategies
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>> -
Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionIf no SQL in the context, returns `sql.empty`, otherwise falls throughReturns the `sql.raw` constantReturns a raw SQL in the context (even if it's not exist)If there is an SQL object attached to the context, returns the name package, the class and the method on which SQL is declared. -
Method Summary
Modifier and TypeMethodDescriptionstatic DefaultNameStrategyReturns the enum constant of this type with the specified name.static DefaultNameStrategy[]values()Returns an array containing the constants of this enum type, in the order they are declared.Methods inherited from class java.lang.Enum
clone, compareTo, describeConstable, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOfMethods inherited from interface com.codahale.metrics.jdbi3.strategies.StatementNameStrategy
getStatementName
-
Enum Constant Details
-
CHECK_EMPTY
If no SQL in the context, returns `sql.empty`, otherwise falls through -
SQL_OBJECT
If there is an SQL object attached to the context, returns the name package, the class and the method on which SQL is declared. If not SQL object is attached, falls through -
NAIVE_NAME
Returns a raw SQL in the context (even if it's not exist) -
CONSTANT_SQL_RAW
Returns the `sql.raw` constant
-
-
Method Details
-
values
Returns an array containing the constants of this enum type, in the order they are declared.- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
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
-