Interface SelectRenderContext
- All Known Implementing Classes:
SqlServerSelectRenderContext
public interface SelectRenderContext
Render context specifically for
SELECT
statements. This interface declares rendering hooks that are called
before/after/during a specific SELECT
clause part. The rendering content is appended directly after/before an
element without further whitespace processing. Hooks are responsible for adding required surrounding whitespaces.- Since:
- 1.1
- Author:
- Mark Paluch, Myeonghyeon Lee, Jens Schauder, Chirag Tailor
-
Method Summary
Modifier and TypeMethodDescriptiondefault Function<Select,
? extends CharSequence> Customization hook: Rendition of a part afterFROM
table.default Function<Select,
? extends CharSequence> afterOrderBy
(boolean hasOrderBy) Customization hook: Rendition of a part afterORDER BY
.default Function<Select,
? extends CharSequence> Customization hook: Rendition of a part after theSELECT
list and before anyFROM
renderings.default String
evaluateOrderByNullHandling
(Sort.NullHandling nullHandling) Customization hook: Rendition of the null handling option for anORDER BY
sort expression.
-
Method Details
-
afterSelectList
Customization hook: Rendition of a part after theSELECT
list and before anyFROM
renderings. Renders an empty string by default.- Returns:
- render
Function
invoked after renderingSELECT
list.
-
afterFromTable
Customization hook: Rendition of a part afterFROM
table. Renders an empty string by default.- Returns:
- render
Function
invoked after renderingFROM
table.
-
afterOrderBy
Customization hook: Rendition of a part afterORDER BY
. The rendering function is called always, regardless whetherORDER BY
exists or not.Renders lock, limit and offset clause as appropriate.
-
evaluateOrderByNullHandling
Customization hook: Rendition of the null handling option for anORDER BY
sort expression.- Parameters:
nullHandling
- theSort.NullHandling
for theORDER BY
sort expression. Must not be null.- Returns:
- render
String
SQL text to be included in anORDER BY
sort expression. - Since:
- 2.4
-