本文整理汇总了Java中org.example.domain.query.QOrder类的典型用法代码示例。如果您正苦于以下问题:Java QOrder类的具体用法?Java QOrder怎么用?Java QOrder使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
QOrder类属于org.example.domain.query包,在下文中一共展示了QOrder类的6个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: fetch
import org.example.domain.query.QOrder; //导入依赖的package包/类
/**
* Eagerly fetch this association loading the specified properties.
*/
@SafeVarargs
public final R fetch(TQProperty<QOrder>... properties) {
return fetchProperties(properties);
}
示例2: where
import org.example.domain.query.QOrder; //导入依赖的package包/类
/**
* Start a new typed query.
*/
protected QOrder where() {
return new QOrder(db());
}
示例3: text
import org.example.domain.query.QOrder; //导入依赖的package包/类
/**
* Start a new document store query.
*/
protected QOrder text() {
return new QOrder(db()).text();
}
示例4: where
import org.example.domain.query.QOrder; //导入依赖的package包/类
/**
* Start a new typed query.
*/
public QOrder where() {
return new QOrder(db());
}
示例5: text
import org.example.domain.query.QOrder; //导入依赖的package包/类
/**
* Start a new document store query.
*/
public QOrder text() {
return new QOrder(db()).text();
}
示例6: simple
import org.example.domain.query.QOrder; //导入依赖的package包/类
@Test
public void simple() {
LoadExampleData.load();
Date oneWeekAgo = new Date(System.currentTimeMillis());
ExpressionList<Order> recentNewOrders = new QOrder()
.orderDate.after(oneWeekAgo)
.status.eq(Order.Status.NEW)
.getExpressionList();
QCustomer cus = QCustomer.alias();
QContact con = QContact.alias();
List<Customer> customers = new QCustomer()
// query tuning
.select(cus.name, cus.inactive)
.contacts.fetch(con.email, con.firstName)
.contacts.notes.fetchAll()
// predicates
.name.ilike("Rob")
.orders.filterMany(recentNewOrders)
.findList();
// ExpressionList<OrderDetail> detailsFilter = new QOrderDetail()
// .unitPrice.isNotNull()
// .getExpressionList();
//
// Customer cust = Customer.find.ref(1L);
//
// new QOrder()
// .status.in(Order.Status.APPROVED, Order.Status.COMPLETE)
// .customer.equalTo(cust)
// .details.filterMany(detailsFilter)
// .findList();
// new QOrder()
// .id.greaterThan(1)
// .findEach(new QueryEachConsumer<Order>() {
// @Override
// public void accept(Order order) {
// Customer customer = order.getCustomer();
// List<Contact> contacts = customer.getContacts();
// System.out.println(contacts);
// }
// });
}