@Status(stage=PRODUCTION, unitTests=COMPLETE) @Reviews(value=@Review(by="Kees Schotanus",at="2009-04-13")) public class OrderByColumn extends Object implements Serializable
OrderByColumn(String, Order, Class)
for further information.OrderByClause
,
Serialized FormConstructor and Description |
---|
OrderByColumn(OrderByColumn orderByColumn)
Copy constructor.
|
OrderByColumn(String columnName)
Constructs this OrderByColumn from the supplied columnName.
|
OrderByColumn(String columnName,
Order order)
Constructs this OrderByColumn from the supplied columnName and order.
|
OrderByColumn(String columnName,
Order order,
Class<T> enumeration)
Constructs this OrderByColumn that will be ordered using a decode function.
|
Modifier and Type | Method and Description |
---|---|
boolean |
equals(Object object)
Determines whether this OrderByColumn is equal to the supplied object.
|
String |
getColumnName()
Gets the name of this OrderByColumn.
|
Order |
getOrdering()
Gets the order of this OrderByColumn.
|
int |
hashCode()
Computes the hash code of this OrderByColumn.
|
Order |
setOrdering(Order order)
Sets the order for this OrderByColumn.
|
void |
toggleOrdering()
Toggles the order (ascending/descending) for this OrderByColumn.
|
String |
toOrderByString(Locale locale)
Creates a String that can be used in an order by clause.
|
String |
toString()
Creates a String representation of this OrderByColumn.
|
public OrderByColumn(OrderByColumn orderByColumn)
orderByColumn
- The OrderByColumn to copy information from.NullPointerException
- When the supplied orderByColumn is null.public OrderByColumn(String columnName)
columnName
- Name of the column.IllegalArgumentException
- When the supplied columnName is empty.NullPointerException
- When the supplied columnName is null.public OrderByColumn(String columnName, Order order)
columnName
- Name of the column.order
- The order for this OrderByColumn.IllegalArgumentException
- When the supplied columnName is empty.NullPointerException
- When either the supplied columnName or order is null.public OrderByColumn(String columnName, Order order, Class<T> enumeration)
decode(expression, code, value [,code, value]... [,defaultValue])
T
- Type of the enumeration.columnName
- Name of the column.
order
- The order for this OrderByColumn.enumeration
- The enumeration to get the code/value pairs from.IllegalArgumentException
- When the supplied columnName is empty.NullPointerException
- When either the supplied columnName, order or enumeration is null.public String getColumnName()
public Order getOrdering()
public Order setOrdering(Order order)
order
- The order for this OrderByColumn.NullPointerException
- When the supplied order is null.public void toggleOrdering()
public boolean equals(Object object)
public int hashCode()
public String toString()
public String toOrderByString(Locale locale)
locale
- The Locale to localize the description of the localized constants that server as the values in the DECODE
function.
Copyright © 2008–2018. All rights reserved.