Database 为什么jooq中没有orderBy(Collection<;Field>;fields)方法?
在jooqapi中有Database 为什么jooq中没有orderBy(Collection<;Field>;fields)方法?,database,jooq,Database,Jooq,在jooqapi中有 ... SelectSeekStepN<R> orderBy(Collection<? extends SortField<?>> fields); SelectSeekStepN<R> orderBy(Field<?>... fields); ... 每个字段实现GroupField,所以我可以用集合参数调用它。在jOOQ 3.10之前,有一种签名方法 orderBy(Collection<? exte
...
SelectSeekStepN<R> orderBy(Collection<? extends SortField<?>> fields);
SelectSeekStepN<R> orderBy(Field<?>... fields);
...
每个
字段
实现GroupField
,所以我可以用集合
参数调用它。在jOOQ 3.10之前,有一种签名方法
orderBy(Collection<? extends SortField<?>>)
。。。这意味着您现在可以传递一个
列表,在jooq3.10之前,已经有了一种签名方法
orderBy(Collection<? extends SortField<?>>)
。。。这意味着您现在可以传递一个列表。在3.10中,使用OrderField
接口解决了这种不一致性,该接口由Field
实现。在3.10之前的版本中,我无法将集合
传递到orderBy()
中<代码>字段
未实现排序字段
。(但我可以传递字段[]
,因为有orderBy(字段[]…字段)
-这很奇怪)现在在3.10中我可以传递集合
,因为API中有一个新方法:orderBy(收集哦,我明白了,我很抱歉。是的,当然,你完全正确。这正是引入OrderField
:)的原因。)我会解决这个问题……3.10版中,似乎使用了由字段实现的OrderField
接口解决了这种不一致性。在3.10版之前的版本中,我无法将集合传递到orderBy()
字段未实现SortField
(但我可以传递字段[]
因为现在3.10中有了orderBy(Field[]…fields)
-这很奇怪),我可以通过Collection
,因为API中有一个新方法:orderBy(CollectionOh,我明白了,我很抱歉。是的,你完全正确。这正是引入OrderField
:)的原因。我会修正答案。。。
orderBy(Collection<? extends SortField<?>>)
orderBy(Collection<? extends OrderField<?>>)