Class SimpleCaseModel<T>
java.lang.Object
org.mybatis.dynamic.sql.select.caseexpression.SimpleCaseModel<T>
- All Implemented Interfaces:
BasicColumn,SortSpecification
-
Nested Class Summary
Nested Classes -
Method Summary
Modifier and TypeMethodDescriptionalias()Returns the columns alias if one has been specified.Returns a new instance of a BasicColumn with the alias set.column()Returns a new instance of the SortSpecification that should render as descending in an ORDER BY clause.render(RenderingContext renderingContext) Returns a rendering of the column.renderForOrderBy(RenderingContext renderingContext) Return a fragment rendered for use in an ORDER BY clause.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.mybatis.dynamic.sql.BasicColumn
jdbcType, renderingStrategy, typeHandler
-
Method Details
-
column
-
whenConditions
-
elseValue
-
alias
Description copied from interface:BasicColumnReturns the columns alias if one has been specified.- Specified by:
aliasin interfaceBasicColumn- Returns:
- the column alias
-
as
Description copied from interface:BasicColumnReturns a new instance of a BasicColumn with the alias set.- Specified by:
asin interfaceBasicColumn- Parameters:
alias- the column alias to set- Returns:
- new instance with alias set
-
descending
Description copied from interface:SortSpecificationReturns a new instance of the SortSpecification that should render as descending in an ORDER BY clause.- Specified by:
descendingin interfaceSortSpecification- Returns:
- new instance of SortSpecification
-
renderForOrderBy
Description copied from interface:SortSpecificationReturn a fragment rendered for use in an ORDER BY clause. The fragment should include "DESC" if a descending order is desired.- Specified by:
renderForOrderByin interfaceSortSpecification- Parameters:
renderingContext- the current rendering context- Returns:
- a rendered fragment and parameters if applicable
-
render
Description copied from interface:BasicColumnReturns a rendering of the column. The rendered fragment should include the table alias based on the TableAliasCalculator in the RenderingContext. The fragment could contain prepared statement parameter markers and associated parameter values if desired.- Specified by:
renderin interfaceBasicColumn- Parameters:
renderingContext- the rendering context (strategy, sequence, etc.)- Returns:
- a rendered SQL fragment and, optionally, parameters associated with the fragment
-