org.qi4j.api.query.grammar

## Class OrderBy

- java.lang.Object
- - org.qi4j.api.query.grammar.OrderBy

-     public class OrderBy
      extends Object

  Query sorting segment.

- - ### Nested Class Summary

    Nested Classes
    Modifier and Type | Class and Description
    --- | ---
    `static class` | `OrderBy.Order` Order direction.

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `OrderBy(PropertyFunction<?> propertyReference, OrderBy.Order order)` Constructor.

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `OrderBy.Order` | `order()` Getter.
    `PropertyFunction<?>` | `property()` Getter.
    `String` | `toString()`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

- - ### Constructor Detail

    - #### OrderBy

          public OrderBy(PropertyFunction<?> propertyReference,
                 OrderBy.Order order)

      Constructor.
      Parameters:
        `propertyReference` - property that determines the order; cannot be null
        `order` - direction
      Throws:
        `IllegalArgumentException` - - If property is null

  - ### Method Detail

    - #### property

          public PropertyFunction<?> property()

      Getter.
      Returns:
        property; cannot be null

    - #### order

          public OrderBy.Order order()

      Getter.
      Returns:
        direction; cannot be null

    - #### toString

          public String toString()

      Overrides:
        `toString` in class `Object`