Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement options for ZRANGE, ZRANGEBYSCORE, ZREVRANGE, ZREVRANGEBYSCORE #78

Closed
wants to merge 2 commits into from

Conversation

brstgt
Copy link
Contributor

@brstgt brstgt commented Oct 7, 2022

No description provided.

@@ -42,9 +42,14 @@ public function add(array $data): Promise
*
* @return Promise
*/
public function getRange(int $start, int $end): Promise
public function getRange(int $start, int $end, RangeOptions $options = null): Promise
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
public function getRange(int $start, int $end, RangeOptions $options = null): Promise
public function getRange(int $start, int $end, ?RangeOptions $options = null): Promise

return $this->withScores;
}

public function withOffset(int $offset, int $count): self
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Shouldn't this be called withLimit instead?

@@ -64,9 +74,14 @@ public function getReverseRange(int $start, int $end): Promise
*
* @return Promise
*/
public function getRangeByScore(float $min, float $max): Promise
public function getRangeByScore(float $min, float $max, RangeByScoreOptions $options = null): Promise
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
public function getRangeByScore(float $min, float $max, RangeByScoreOptions $options = null): Promise
public function getRangeByScore(float $min, float $max, ?RangeByScoreOptions $options = null): Promise

@@ -75,9 +90,14 @@ public function getRangeByScore(float $min, float $max): Promise
*
* @return Promise
*/
public function getReverseRangeByScore(float $min, float $max): Promise
public function getReverseRangeByScore(float $min, float $max, RangeByScoreOptions $options = null): Promise
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
public function getReverseRangeByScore(float $min, float $max, RangeByScoreOptions $options = null): Promise
public function getReverseRangeByScore(float $min, float $max, ?RangeByScoreOptions $options = null): Promise

@trowski trowski mentioned this pull request Dec 31, 2022
@trowski
Copy link
Member

trowski commented Feb 18, 2023

Merged in b720d08.

@trowski trowski closed this Feb 18, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

3 participants