Example usage for org.apache.wicket.util.string StringList StringList

List of usage examples for org.apache.wicket.util.string StringList StringList

Introduction

In this page you can find the example usage for org.apache.wicket.util.string StringList StringList.

Prototype

public StringList() 

Source Link

Document

Constructor.

Usage

From source file:com.locke.library.persistence.dao.jpa.JpaQuery.java

License:Apache License

/**
 * Override this method to provide multi-level sorting for a field
 * /*w  w w.  j  a  v a2  s  . c o m*/
 * @param ascending
 *            Order by clause
 */
protected void onAscending(final Ascending ascending) {
    final StringList fields = new StringList();
    for (final String field : ascending.getFields()) {
        fields.add("target." + field);
    }
    this.queryText.add("order by " + fields.join() + " asc");
}

From source file:com.locke.library.persistence.dao.jpa.JpaQuery.java

License:Apache License

/**
 * Override this method to provide multi-level sorting for a field
 * /* w w  w  .  j  a  v a 2s  .co m*/
 * @param descending
 *            Order by clause
 */
protected void onDescending(final Descending descending) {
    final StringList fields = new StringList();
    for (final String field : descending.getFields()) {
        fields.add("target." + field);
    }
    this.queryText.add("order by " + fields.join() + " desc");
}