@@ -97,9 +97,9 @@ class QueryStringProperty extends QueryProperty {
9797 return _opList (list, ConditionOp .notIn, caseSensitive);
9898 }
9999
100- /// Using [withEqual] is deprecated, use [greaterOrEqual] instead.
101100 Condition greaterThan (String p,
102- {bool caseSensitive = false , bool withEqual = false }) {
101+ {bool caseSensitive = false ,
102+ @Deprecated ('Use greaterOrEqual() instead' ) bool withEqual = false }) {
103103 if (withEqual) {
104104 return greaterOrEqual (p, caseSensitive: caseSensitive);
105105 } else {
@@ -111,9 +111,9 @@ class QueryStringProperty extends QueryProperty {
111111 return _op (p, ConditionOp .greaterOrEq, caseSensitive);
112112 }
113113
114- /// Using [withEqual] is deprecated, use [lessOrEqual] instead.
115114 Condition lessThan (String p,
116- {bool caseSensitive = false , bool withEqual = false }) {
115+ {bool caseSensitive = false ,
116+ @Deprecated ('Use lessOrEqual() instead' ) bool withEqual = false }) {
117117 if (withEqual) {
118118 return lessOrEqual (p, caseSensitive: caseSensitive);
119119 } else {
@@ -589,8 +589,9 @@ class Query<T> {
589589 ///
590590 /// Call with offset=0 to reset to the default behavior,
591591 /// i.e. starting from the first element.
592- void offset (int offset) {
592+ Query < T > offset (int offset) {
593593 checkObx (bindings.obx_query_offset (_cQuery, offset));
594+ return this ;
594595 }
595596
596597 /// Configure a [limit] for this query.
@@ -601,8 +602,9 @@ class Query<T> {
601602 ///
602603 /// Call with limit=0 to reset to the default behavior -
603604 /// zero limit means no limit applied.
604- void limit (int limit) {
605+ Query < T > limit (int limit) {
605606 checkObx (bindings.obx_query_limit (_cQuery, limit));
607+ return this ;
606608 }
607609
608610 /// Returns the number of matching Objects.
@@ -643,10 +645,9 @@ class Query<T> {
643645 }
644646
645647 /// Finds Objects matching the query and returns their IDs.
646- ///
647- /// [offset] and [limit] are deprecated, explicitly call
648- /// the equally named methods.
649- List <int > findIds ({int offset = 0 , int limit = 0 }) {
648+ List <int > findIds (
649+ {@Deprecated ('Use offset() instead' ) int offset = 0 ,
650+ @Deprecated ('Use limit() instead' ) int limit = 0 }) {
650651 if (offset > 0 ) {
651652 this .offset (offset);
652653 }
@@ -666,10 +667,9 @@ class Query<T> {
666667 }
667668
668669 /// Finds Objects matching the query.
669- ///
670- /// [offset] and [limit] are deprecated, explicitly call
671- /// the equally named methods.
672- List <T > find ({int offset = 0 , int limit = 0 }) {
670+ List <T > find (
671+ {@Deprecated ('Use offset() instead' ) int offset = 0 ,
672+ @Deprecated ('Use limit() instead' ) int limit = 0 }) {
673673 if (offset > 0 ) {
674674 this .offset (offset);
675675 }
0 commit comments